camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [3/3] camel git commit: Fixed CS
Date Wed, 05 Jul 2017 08:34:22 GMT
Fixed CS


Project: http://git-wip-us.apache.org/repos/asf/camel/repo
Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/e6bcdba1
Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/e6bcdba1
Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/e6bcdba1

Branch: refs/heads/master
Commit: e6bcdba111d267bd90e29ce2261dde0aae3a196c
Parents: 7376cc4
Author: Claus Ibsen <davsclaus@apache.org>
Authored: Wed Jul 5 10:14:19 2017 +0200
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Wed Jul 5 10:14:19 2017 +0200

----------------------------------------------------------------------
 .../java/org/apache/camel/support/ReloadStrategySupport.java  | 3 +--
 .../src/main/java/org/apache/camel/util/LRUCacheFactory.java  | 7 +++++--
 2 files changed, 6 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/e6bcdba1/camel-core/src/main/java/org/apache/camel/support/ReloadStrategySupport.java
----------------------------------------------------------------------
diff --git a/camel-core/src/main/java/org/apache/camel/support/ReloadStrategySupport.java
b/camel-core/src/main/java/org/apache/camel/support/ReloadStrategySupport.java
index ecc040c..41d2600 100644
--- a/camel-core/src/main/java/org/apache/camel/support/ReloadStrategySupport.java
+++ b/camel-core/src/main/java/org/apache/camel/support/ReloadStrategySupport.java
@@ -22,7 +22,6 @@ import java.util.ArrayList;
 import java.util.List;
 import java.util.Map;
 
-import org.apache.camel.util.LRUCacheFactory;
 import org.w3c.dom.Document;
 import org.w3c.dom.Node;
 import org.w3c.dom.NodeList;
@@ -35,7 +34,7 @@ import org.apache.camel.model.RouteDefinition;
 import org.apache.camel.model.RoutesDefinition;
 import org.apache.camel.spi.ReloadStrategy;
 import org.apache.camel.util.CollectionStringBuffer;
-import org.apache.camel.util.LRUCache;
+import org.apache.camel.util.LRUCacheFactory;
 import org.apache.camel.util.ObjectHelper;
 import org.apache.camel.util.StringHelper;
 import org.apache.camel.util.XmlLineNumberParser;

http://git-wip-us.apache.org/repos/asf/camel/blob/e6bcdba1/camel-core/src/main/java/org/apache/camel/util/LRUCacheFactory.java
----------------------------------------------------------------------
diff --git a/camel-core/src/main/java/org/apache/camel/util/LRUCacheFactory.java b/camel-core/src/main/java/org/apache/camel/util/LRUCacheFactory.java
index 71363b3..97d5018 100644
--- a/camel-core/src/main/java/org/apache/camel/util/LRUCacheFactory.java
+++ b/camel-core/src/main/java/org/apache/camel/util/LRUCacheFactory.java
@@ -29,17 +29,20 @@ public final class LRUCacheFactory {
 
     private static final Logger LOG = LoggerFactory.getLogger(LRUCacheFactory.class);
 
-    private static final AtomicBoolean init = new AtomicBoolean();
+    private static final AtomicBoolean INIT = new AtomicBoolean();
 
     private LRUCacheFactory() {
     }
 
+    /**
+     * Warm-up the LRUCache to startup Apache Camel faster.
+     */
     @SuppressWarnings("unchecked")
     public static void warmUp() {
         // create a dummy map in a separate thread to warm-up the Caffeine cache concurrently
         // while Camel is starting up. This allows us to overall startup Camel a bit faster
         // as Caffeine takes 150+ millis to initialize.
-        if (init.compareAndSet(false, true)) {
+        if (INIT.compareAndSet(false, true)) {
             // only need to init Caffeine once in the JVM/classloader
             Runnable task = () -> {
                 StopWatch watch = new StopWatch();


Mime
View raw message