camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject svn commit: r1328826 - in /camel/branches/camel-2.8.x: ./ camel-core/src/main/java/org/apache/camel/builder/xml/ camel-core/src/main/java/org/apache/camel/component/log/ camel-core/src/main/java/org/apache/camel/component/mock/ camel-core/src/main/java...
Date Sun, 22 Apr 2012 09:17:54 GMT
Author: davsclaus
Date: Sun Apr 22 09:17:53 2012
New Revision: 1328826

URL: http://svn.apache.org/viewvc?rev=1328826&view=rev
Log:
CAMEL-5199: Ensure to use english locale for toLowerCase and toUpperCase.

Modified:
    camel/branches/camel-2.8.x/   (props changed)
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/TimeUnitAdapter.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/log/LogComponent.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/mock/TimeClause.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultHeaderFilterStrategy.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultShutdownStrategy.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/model/SamplingDefinition.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/processor/SamplingThrottler.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CamelContextHelper.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CaseInsensitiveMap.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/GZIPHelper.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/IntrospectionSupport.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/Time.java
    camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/view/NodeData.java
    camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/JmxInstrumentationWithConnectorTest.java
    camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/ManagedShutdownStrategyTest.java
    camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceCountTest.java
    camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceTest.java

Propchange: camel/branches/camel-2.8.x/
------------------------------------------------------------------------------
  Merged /camel/trunk:r1328822
  Merged /camel/branches/camel-2.9.x:r1328823

Propchange: camel/branches/camel-2.8.x/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/TimeUnitAdapter.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/TimeUnitAdapter.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/TimeUnitAdapter.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/builder/xml/TimeUnitAdapter.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.builder.xml;
 
+import java.util.Locale;
 import java.util.concurrent.TimeUnit;
 
 import javax.xml.bind.annotation.adapters.XmlAdapter;
@@ -39,7 +40,7 @@ public class TimeUnitAdapter extends Xml
     public TimeUnit unmarshal(String v) throws Exception {
         TimeUnit result = null;
         if (v != null) {
-            result = TimeUnit.valueOf(v.toUpperCase());
+            result = TimeUnit.valueOf(v.toUpperCase(Locale.ENGLISH));
         }
         return result;
     }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/log/LogComponent.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/log/LogComponent.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/log/LogComponent.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/log/LogComponent.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.component.log;
 
+import java.util.Locale;
 import java.util.Map;
 
 import org.apache.camel.Endpoint;
@@ -64,7 +65,7 @@ public class LogComponent extends Defaul
      */
     protected LoggingLevel getLoggingLevel(Map<String, Object> parameters) {
         String levelText = getAndRemoveParameter(parameters, "level", String.class, "INFO");
-        return LoggingLevel.valueOf(levelText.toUpperCase());
+        return LoggingLevel.valueOf(levelText.toUpperCase(Locale.ENGLISH));
     }
 
 }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/mock/TimeClause.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/mock/TimeClause.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/mock/TimeClause.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/component/mock/TimeClause.java
Sun Apr 22 09:17:53 2012
@@ -17,6 +17,7 @@
 package org.apache.camel.component.mock;
 
 import java.util.Date;
+import java.util.Locale;
 import java.util.concurrent.TimeUnit;
 
 import org.apache.camel.Exchange;
@@ -180,7 +181,7 @@ public class TimeClause extends BinaryPr
         if (timeFrom == null) {
             return "no later than " + timeTo + " " + getOperationText() + " (" + was + ")";
         } else {
-            return "between " + timeFrom.getNumber() + "-" + timeTo.getNumber() + " " + timeTo.getTimeUnit().toString().toLowerCase()
+            return "between " + timeFrom.getNumber() + "-" + timeTo.getNumber() + " " + timeTo.getTimeUnit().toString().toLowerCase(Locale.ENGLISH)
                     + " " + getOperationText() + " (" + was + ")";
         }
     }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultHeaderFilterStrategy.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultHeaderFilterStrategy.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultHeaderFilterStrategy.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultHeaderFilterStrategy.java
Sun Apr 22 09:17:53 2012
@@ -17,6 +17,7 @@
 package org.apache.camel.impl;
 
 import java.util.HashSet;
+import java.util.Locale;
 import java.util.Set;
 import java.util.regex.Pattern;
 
@@ -218,7 +219,7 @@ public class DefaultHeaderFilterStrategy
             
         if (filter != null) {
             if (isLowerCase()) {
-                if (filter.contains(headerName.toLowerCase())) {
+                if (filter.contains(headerName.toLowerCase(Locale.ENGLISH))) {
                     return true;
                 }
             } else {

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultShutdownStrategy.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultShutdownStrategy.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultShutdownStrategy.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/DefaultShutdownStrategy.java
Sun Apr 22 09:17:53 2012
@@ -20,6 +20,7 @@ import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Comparator;
 import java.util.List;
+import java.util.Locale;
 import java.util.concurrent.ExecutionException;
 import java.util.concurrent.ExecutorService;
 import java.util.concurrent.Future;
@@ -117,7 +118,7 @@ public class DefaultShutdownStrategy ext
         }
 
         if (timeout > 0) {
-            LOG.info("Starting to graceful shutdown " + routesOrdered.size() + " routes (timeout
" + timeout + " " + timeUnit.toString().toLowerCase() + ")");
+            LOG.info("Starting to graceful shutdown " + routesOrdered.size() + " routes (timeout
" + timeout + " " + timeUnit.toString().toLowerCase(Locale.ENGLISH) + ")");
         } else {
             LOG.info("Starting to graceful shutdown " + routesOrdered.size() + " routes (no
timeout)");
         }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/impl/ScheduledPollConsumer.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.impl;
 
+import java.util.Locale;
 import java.util.concurrent.ScheduledExecutorService;
 import java.util.concurrent.ScheduledFuture;
 import java.util.concurrent.TimeUnit;
@@ -284,13 +285,13 @@ public abstract class ScheduledPollConsu
         if (isUseFixedDelay()) {
             if (LOG.isDebugEnabled()) {
                 LOG.debug("Scheduling poll (fixed delay) with initialDelay: {}, delay: {}
({}) for: {}",
-                        new Object[]{getInitialDelay(), getDelay(), getTimeUnit().name().toLowerCase(),
getEndpoint()});
+                        new Object[]{getInitialDelay(), getDelay(), getTimeUnit().name().toLowerCase(Locale.ENGLISH),
getEndpoint()});
             }
             future = executor.scheduleWithFixedDelay(this, getInitialDelay(), getDelay(),
getTimeUnit());
         } else {
             if (LOG.isDebugEnabled()) {
                 LOG.debug("Scheduling poll (fixed rate) with initialDelay: {}, delay: {}
({}) for: {}",
-                        new Object[]{getInitialDelay(), getDelay(), getTimeUnit().name().toLowerCase(),
getEndpoint()});
+                        new Object[]{getInitialDelay(), getDelay(), getTimeUnit().name().toLowerCase(Locale.ENGLISH),
getEndpoint()});
             }
             future = executor.scheduleAtFixedRate(this, getInitialDelay(), getDelay(), getTimeUnit());
         }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/model/SamplingDefinition.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/model/SamplingDefinition.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/model/SamplingDefinition.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/model/SamplingDefinition.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.model;
 
+import java.util.Locale;
 import java.util.concurrent.TimeUnit;
 import javax.xml.bind.annotation.XmlAccessType;
 import javax.xml.bind.annotation.XmlAccessorType;
@@ -67,7 +68,7 @@ public class SamplingDefinition extends 
             return "Sample[1 Exchange per " + getMessageFrequency() + " messages received
-> " + getOutputs() + "]";
         } else {
             TimeUnit tu = getUnits() != null ? getUnits() : TimeUnit.SECONDS;
-            return "Sample[1 Exchange per " + getSamplePeriod() + " " + tu.toString().toLowerCase()
+ " -> " + getOutputs() + "]";
+            return "Sample[1 Exchange per " + getSamplePeriod() + " " + tu.toString().toLowerCase(Locale.ENGLISH)
+ " -> " + getOutputs() + "]";
         }
     }
 
@@ -82,7 +83,7 @@ public class SamplingDefinition extends 
             return "sample[1 Exchange per " + getMessageFrequency() + " messages received]";
         } else {
             TimeUnit tu = getUnits() != null ? getUnits() : TimeUnit.SECONDS;
-            return "sample[1 Exchange per " + getSamplePeriod() + " " + tu.name().toLowerCase()
+ "]";
+            return "sample[1 Exchange per " + getSamplePeriod() + " " + tu.name().toLowerCase(Locale.ENGLISH)
+ "]";
         }
     }
 

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/processor/SamplingThrottler.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/processor/SamplingThrottler.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/processor/SamplingThrottler.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/processor/SamplingThrottler.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.processor;
 
+import java.util.Locale;
 import java.util.concurrent.TimeUnit;
 
 import org.apache.camel.AsyncCallback;
@@ -78,7 +79,7 @@ public class SamplingThrottler extends D
         if (messageFrequency > 0) {
             return "SamplingThrottler[1 exchange per: " + messageFrequency + " messages received
-> " + getProcessor() + "]";
         } else {
-            return "SamplingThrottler[1 exchange per: " + samplePeriod + " " + units.toString().toLowerCase()
+ " -> " + getProcessor() + "]";
+            return "SamplingThrottler[1 exchange per: " + samplePeriod + " " + units.toString().toLowerCase(Locale.ENGLISH)
+ " -> " + getProcessor() + "]";
         }
     }
 
@@ -86,7 +87,7 @@ public class SamplingThrottler extends D
         if (messageFrequency > 0) {
             return "samplingThrottler[1 exchange per: " + messageFrequency + " messages received]";
         } else {
-            return "samplingThrottler[1 exchange per: " + samplePeriod + " " + units.toString().toLowerCase()
+ "]";
+            return "samplingThrottler[1 exchange per: " + samplePeriod + " " + units.toString().toLowerCase(Locale.ENGLISH)
+ "]";
         }
     }
 

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CamelContextHelper.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CamelContextHelper.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CamelContextHelper.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CamelContextHelper.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,8 @@
  */
 package org.apache.camel.util;
 
+import java.util.Locale;
+
 import org.apache.camel.CamelContext;
 import org.apache.camel.Endpoint;
 import org.apache.camel.Exchange;
@@ -322,7 +324,7 @@ public final class CamelContextHelper {
         // ensure we support property placeholders
         String s = camelContext.resolvePropertyPlaceholders(text);
         if (s != null) {
-            s = s.trim().toLowerCase();
+            s = s.trim().toLowerCase(Locale.ENGLISH);
             if (s.equals("true") || s.equals("false")) {
                 return "true".equals(s) ? Boolean.TRUE : Boolean.FALSE;
             } else {

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CaseInsensitiveMap.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CaseInsensitiveMap.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CaseInsensitiveMap.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/CaseInsensitiveMap.java
Sun Apr 22 09:17:53 2012
@@ -18,6 +18,7 @@ package org.apache.camel.util;
 
 import java.util.HashMap;
 import java.util.HashSet;
+import java.util.Locale;
 import java.util.Map;
 import java.util.Set;
 
@@ -142,7 +143,7 @@ public class CaseInsensitiveMap extends 
     }
 
     private static String assembleKey(Object key) {
-        String s = key.toString().toLowerCase();
+        String s = key.toString().toLowerCase(Locale.ENGLISH);
         if (s.startsWith("camel")) {
             // use intern String for headers which is Camel* headers
             // this reduces memory allocations needed for those common headers

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/GZIPHelper.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/GZIPHelper.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/GZIPHelper.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/GZIPHelper.java
Sun Apr 22 09:17:53 2012
@@ -20,6 +20,7 @@ import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.IOException;
 import java.io.InputStream;
+import java.util.Locale;
 import java.util.zip.GZIPInputStream;
 import java.util.zip.GZIPOutputStream;
 
@@ -106,6 +107,6 @@ public final class GZIPHelper {
     }
 
     public static boolean isGzip(String header) {
-        return header != null && header.toLowerCase().contains("gzip");
+        return header != null && header.toLowerCase(Locale.ENGLISH).contains("gzip");
     }
 }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/IntrospectionSupport.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/IntrospectionSupport.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/IntrospectionSupport.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/IntrospectionSupport.java
Sun Apr 22 09:17:53 2012
@@ -88,10 +88,10 @@ public final class IntrospectionSupport 
         String name = method.getName();
         if (name.startsWith("get")) {
             name = name.substring(3);
-            name = name.substring(0, 1).toLowerCase() + name.substring(1);
+            name = name.substring(0, 1).toLowerCase(Locale.ENGLISH) + name.substring(1);
         } else if (name.startsWith("is")) {
             name = name.substring(2);
-            name = name.substring(0, 1).toLowerCase() + name.substring(1);
+            name = name.substring(0, 1).toLowerCase(Locale.ENGLISH) + name.substring(1);
         }
 
         return name;
@@ -105,7 +105,7 @@ public final class IntrospectionSupport 
         String name = method.getName();
         if (name.startsWith("set")) {
             name = name.substring(3);
-            name = name.substring(0, 1).toLowerCase() + name.substring(1);
+            name = name.substring(0, 1).toLowerCase(Locale.ENGLISH) + name.substring(1);
         }
 
         return name;

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/ObjectHelper.java
Sun Apr 22 09:17:53 2012
@@ -35,6 +35,7 @@ import java.util.Collection;
 import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Locale;
 import java.util.Map;
 import java.util.Properties;
 import java.util.Scanner;
@@ -400,7 +401,7 @@ public final class ObjectHelper {
         if (length == 0) {
             return text;
         }
-        String answer = text.substring(0, 1).toUpperCase();
+        String answer = text.substring(0, 1).toUpperCase(Locale.ENGLISH);
         if (length > 1) {
             answer += text.substring(1, length);
         }
@@ -1006,7 +1007,7 @@ public final class ObjectHelper {
     public static String getPropertyName(Method method) {
         String propertyName = method.getName();
         if (propertyName.startsWith("set") && method.getParameterTypes().length ==
1) {
-            propertyName = propertyName.substring(3, 4).toLowerCase() + propertyName.substring(4);
+            propertyName = propertyName.substring(3, 4).toLowerCase(Locale.ENGLISH) + propertyName.substring(4);
         }
         return propertyName;
     }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/Time.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/Time.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/Time.java (original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/util/Time.java Sun
Apr 22 09:17:53 2012
@@ -17,6 +17,7 @@
 package org.apache.camel.util;
 
 import java.util.Date;
+import java.util.Locale;
 import java.util.concurrent.TimeUnit;
 
 /**
@@ -83,6 +84,6 @@ public class Time {
 
     @Override
     public String toString() {
-        return number + " " + timeUnit.toString().toLowerCase();
+        return number + " " + timeUnit.toString().toLowerCase(Locale.ENGLISH);
     }
 }

Modified: camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/view/NodeData.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/view/NodeData.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/view/NodeData.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/main/java/org/apache/camel/view/NodeData.java
Sun Apr 22 09:17:53 2012
@@ -18,6 +18,7 @@ package org.apache.camel.view;
 
 import java.util.ArrayList;
 import java.util.List;
+import java.util.Locale;
 
 import org.apache.camel.model.AggregateDefinition;
 import org.apache.camel.model.BeanDefinition;
@@ -153,7 +154,7 @@ public class NodeData {
             }
         }
         if (isEmpty(this.url) && isNotEmpty(this.nodeType)) {
-            this.url = "http://camel.apache.org/" + this.nodeType.toLowerCase().replace('
', '-') + ".html";
+            this.url = "http://camel.apache.org/" + this.nodeType.toLowerCase(Locale.ENGLISH).replace('
', '-') + ".html";
         }
         if (node instanceof ProcessorDefinition && this.outputs == null) {
             ProcessorDefinition processorType = (ProcessorDefinition)node;

Modified: camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/JmxInstrumentationWithConnectorTest.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/JmxInstrumentationWithConnectorTest.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/JmxInstrumentationWithConnectorTest.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/JmxInstrumentationWithConnectorTest.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.management;
 
+import java.util.Locale;
 import java.util.Random;
 import javax.management.MBeanServerConnection;
 import javax.management.remote.JMXConnector;
@@ -43,7 +44,7 @@ public class JmxInstrumentationWithConne
         String os = System.getProperty("os.name");
         // Does not work on AIX and the problem is hard to identify, could be issues not
allowing to use a custom port
         // java.io.IOException: Failed to retrieve RMIServer stub: javax.naming.NameNotFoundException:
jmxrmi/camel
-        return !os.toLowerCase().contains("aix");
+        return !os.toLowerCase(Locale.ENGLISH).contains("aix");
     }
 
     @Override

Modified: camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/ManagedShutdownStrategyTest.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/ManagedShutdownStrategyTest.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/ManagedShutdownStrategyTest.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/management/ManagedShutdownStrategyTest.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.management;
 
+import java.util.Locale;
 import java.util.concurrent.TimeUnit;
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
@@ -39,7 +40,7 @@ public class ManagedShutdownStrategyTest
         assertEquals(300, timeout.longValue());
 
         TimeUnit unit = (TimeUnit) mbeanServer.getAttribute(on, "TimeUnit");
-        assertEquals("seconds", unit.toString().toLowerCase());
+        assertEquals("seconds", unit.toString().toLowerCase(Locale.ENGLISH));
     }
 
     @Override

Modified: camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceCountTest.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceCountTest.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceCountTest.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceCountTest.java
Sun Apr 22 09:17:53 2012
@@ -16,6 +16,7 @@
  */
 package org.apache.camel.processor;
 
+import java.util.Locale;
 import java.util.concurrent.atomic.AtomicInteger;
 
 import org.apache.camel.ContextTestSupport;
@@ -48,7 +49,7 @@ public class RoutePerformanceCountTest e
     protected boolean canRunOnThisPlatform() {
         String os = System.getProperty("os.name");
         // HP-UX is just to slow to run this test
-        return !os.toLowerCase().contains("hp-ux");
+        return !os.toLowerCase(Locale.ENGLISH).contains("hp-ux");
     }
 
     @Override

Modified: camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceTest.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceTest.java?rev=1328826&r1=1328825&r2=1328826&view=diff
==============================================================================
--- camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceTest.java
(original)
+++ camel/branches/camel-2.8.x/camel-core/src/test/java/org/apache/camel/processor/RoutePerformanceTest.java
Sun Apr 22 09:17:53 2012
@@ -17,6 +17,7 @@
 package org.apache.camel.processor;
 
 import java.util.HashMap;
+import java.util.Locale;
 import java.util.Map;
 import java.util.concurrent.TimeUnit;
 import javax.naming.Context;
@@ -54,7 +55,7 @@ public class RoutePerformanceTest extend
     protected boolean canRunOnThisPlatform() {
         String os = System.getProperty("os.name");
         // HP-UX is just to slow to run this test
-        return !os.toLowerCase().contains("hp-ux");
+        return !os.toLowerCase(Locale.ENGLISH).contains("hp-ux");
     }
 
     @Override



Mime
View raw message