camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davscl...@apache.org
Subject [6/6] camel git commit: CAMEL-8640: Fixed CS
Date Sun, 03 May 2015 09:38:24 GMT
CAMEL-8640: Fixed CS


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

Branch: refs/heads/camel-2.15.x
Commit: 6f8fdc4bbb8fac265b48693770bf2dc3cdc82b24
Parents: 4556db6
Author: Claus Ibsen <davsclaus@apache.org>
Authored: Sun May 3 11:37:35 2015 +0200
Committer: Claus Ibsen <davsclaus@apache.org>
Committed: Sun May 3 11:41:58 2015 +0200

----------------------------------------------------------------------
 .../camel/processor/interceptor/BacklogTracer.java      | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/camel/blob/6f8fdc4b/camel-core/src/main/java/org/apache/camel/processor/interceptor/BacklogTracer.java
----------------------------------------------------------------------
diff --git a/camel-core/src/main/java/org/apache/camel/processor/interceptor/BacklogTracer.java
b/camel-core/src/main/java/org/apache/camel/processor/interceptor/BacklogTracer.java
index fa0dcda..15f9cd2 100644
--- a/camel-core/src/main/java/org/apache/camel/processor/interceptor/BacklogTracer.java
+++ b/camel-core/src/main/java/org/apache/camel/processor/interceptor/BacklogTracer.java
@@ -43,16 +43,16 @@ import org.slf4j.LoggerFactory;
  * This tracer allows to store message tracers per node in the Camel routes. The tracers
  * is stored in a backlog queue (FIFO based) which allows to pull the traced messages on
demand.
  */
-public class BacklogTracer extends ServiceSupport implements InterceptStrategy {
+public final class BacklogTracer extends ServiceSupport implements InterceptStrategy {
 
-    // lets limit the tracer to 100 thousand messages in total
-    public static final int MAX_BACKLOG_SIZE = 100 * 1000;
+    // lets limit the tracer to 10 thousand messages in total
+    public static final int MAX_BACKLOG_SIZE = 10 * 1000;
     private static final Logger LOG = LoggerFactory.getLogger(BacklogTracer.class);
     private final CamelContext camelContext;
     private boolean enabled;
     private final AtomicLong traceCounter = new AtomicLong(0);
     // use a queue with a upper limit to avoid storing too many messages
-    private final Queue<BacklogTracerEventMessage> queue = new LinkedBlockingQueue<>(MAX_BACKLOG_SIZE);
+    private final Queue<BacklogTracerEventMessage> queue = new LinkedBlockingQueue<BacklogTracerEventMessage>(MAX_BACKLOG_SIZE);
     // how many of the last messages to keep in the backlog at total
     private int backlogSize = 1000;
     private boolean removeOnDump = true;
@@ -262,7 +262,7 @@ public class BacklogTracer extends ServiceSupport implements InterceptStrategy
{
     }
 
     public List<BacklogTracerEventMessage> dumpTracedMessages(String nodeId) {
-        List<BacklogTracerEventMessage> answer = new ArrayList<>();
+        List<BacklogTracerEventMessage> answer = new ArrayList<BacklogTracerEventMessage>();
         if (nodeId != null) {
             for (BacklogTracerEventMessage message : queue) {
                 if (nodeId.equals(message.getToNode()) || nodeId.equals(message.getRouteId()))
{
@@ -291,7 +291,7 @@ public class BacklogTracer extends ServiceSupport implements InterceptStrategy
{
     }
 
     public List<BacklogTracerEventMessage> dumpAllTracedMessages() {
-        List<BacklogTracerEventMessage> answer = new ArrayList<>();
+        List<BacklogTracerEventMessage> answer = new ArrayList<BacklogTracerEventMessage>();
         answer.addAll(queue);
         if (isRemoveOnDump()) {
             queue.clear();


Mime
View raw message