camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ningji...@apache.org
Subject svn commit: r1374133 - /camel/trunk/camel-core/src/main/java/org/apache/camel/model/ProcessorDefinition.java
Date Fri, 17 Aug 2012 04:20:40 GMT
Author: ningjiang
Date: Fri Aug 17 04:20:40 2012
New Revision: 1374133

URL: http://svn.apache.org/viewvc?rev=1374133&view=rev
Log:
CAMEL-5515 Fixed the issue of thread Java DSL

Modified:
    camel/trunk/camel-core/src/main/java/org/apache/camel/model/ProcessorDefinition.java

Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/model/ProcessorDefinition.java
URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/model/ProcessorDefinition.java?rev=1374133&r1=1374132&r2=1374133&view=diff
==============================================================================
--- camel/trunk/camel-core/src/main/java/org/apache/camel/model/ProcessorDefinition.java (original)
+++ camel/trunk/camel-core/src/main/java/org/apache/camel/model/ProcessorDefinition.java Fri
Aug 17 04:20:40 2012
@@ -1132,6 +1132,7 @@ public abstract class ProcessorDefinitio
     public ThreadsDefinition threads(int poolSize) {
         ThreadsDefinition answer = threads();
         answer.setPoolSize(poolSize);
+        addOutput(answer);
         return answer;
     }
 
@@ -1146,6 +1147,24 @@ public abstract class ProcessorDefinitio
         ThreadsDefinition answer = threads();
         answer.setPoolSize(poolSize);
         answer.setMaxPoolSize(maxPoolSize);
+        addOutput(answer);
+        return answer;
+    }
+    
+    /**
+     * Continues processing the {@link org.apache.camel.Exchange} using asynchronous routing
engine.
+     *
+     * @param poolSize    the core pool size
+     * @param maxPoolSize the maximum pool size
+     * @param threadName the thread pool name
+     * @return the builder
+     */
+    public ThreadsDefinition threads(int poolSize, int maxPoolSize, String threadName) {
+        ThreadsDefinition answer = threads();
+        answer.setPoolSize(poolSize);
+        answer.setMaxPoolSize(maxPoolSize);
+        answer.setThreadName(threadName);
+        addOutput(answer);
         return answer;
     }
 



Mime
View raw message