Author: davsclaus Date: Mon May 9 13:03:55 2011 New Revision: 1101006 URL: http://svn.apache.org/viewvc?rev=1101006&view=rev Log: CAMEL-3957: Made DefaultExecutorServiceStrategy more easy for end users to extend by more protected method. To be used for a CommonJ WorkManager donation to Apache Camel by Preben.
Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/impl/DefaultExecutorServiceStrategy.java Modified: camel/trunk/camel-core/src/main/java/org/apache/camel/impl/DefaultExecutorServiceStrategy.java URL: http://svn.apache.org/viewvc/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/DefaultExecutorServiceStrategy.java?rev=1101006&r1=1101005&r2=1101006&view=diff ============================================================================== --- camel/trunk/camel-core/src/main/java/org/apache/camel/impl/DefaultExecutorServiceStrategy.java (original) +++ camel/trunk/camel-core/src/main/java/org/apache/camel/impl/DefaultExecutorServiceStrategy.java Mon May 9 13:03:55 2011 @@ -347,7 +347,17 @@ public class DefaultExecutorServiceStrat return answer; } - private void onThreadPoolCreated(ExecutorService executorService, Object source, String threadPoolProfileId) { + /** + * Invoked when a new thread pool is created. + * This implementation will invoke the {@link LifecycleStrategy#onThreadPoolAdd(org.apache.camel.CamelContext, + * java.util.concurrent.ThreadPoolExecutor, String, String, String, String) LifecycleStrategy.onThreadPoolAdd} method, + * which for example will enlist the thread pool in JMX management. + * + * @param executorService the thread pool + * @param source the source to use the thread pool + * @param threadPoolProfileId profile id, if the thread pool was created from a thread pool profile + */ + protected void onThreadPoolCreated(ExecutorService executorService, Object source, String threadPoolProfileId) { // add to internal list of thread pools executorServices.add(executorService);