Package org.apache.camel.util.concurrent

Examples of org.apache.camel.util.concurrent.CamelThreadFactory


        // now call strategy to allow custom logic
        onNewExecutorService(executorService);
    }

    private ThreadFactory createThreadFactory(String name, boolean isDaemon) {
        ThreadFactory threadFactory = new CamelThreadFactory(threadNamePattern, name, isDaemon);
        return threadFactory;
    }
View Full Code Here


        // now call strategy to allow custom logic
        onNewExecutorService(executorService);
    }

    private ThreadFactory createThreadFactory(String name, boolean isDaemon) {
        ThreadFactory threadFactory = new CamelThreadFactory(threadNamePattern, name, isDaemon);
        return threadFactory;
    }
View Full Code Here

    protected TaskExecutor createDefaultTaskExecutor() {
        String pattern = endpoint.getCamelContext().getExecutorServiceManager().getThreadNamePattern();
        String beanName = getBeanName();

        SimpleAsyncTaskExecutor answer = new SimpleAsyncTaskExecutor(beanName);
        answer.setThreadFactory(new CamelThreadFactory(pattern, beanName, true));
        return answer;
    }
View Full Code Here

        // now call strategy to allow custom logic
        onNewExecutorService(executorService);
    }

    private ThreadFactory createThreadFactory(String name, boolean isDaemon) {
        ThreadFactory threadFactory = new CamelThreadFactory(threadNamePattern, name, isDaemon);
        return threadFactory;
    }
View Full Code Here

        // now call strategy to allow custom logic
        onNewExecutorService(executorService);
    }

    private ThreadFactory createThreadFactory(String name, boolean isDaemon) {
        ThreadFactory threadFactory = new CamelThreadFactory(threadNamePattern, name, isDaemon);
        return threadFactory;
    }
View Full Code Here

        if (consumer.getConfiguration().isOrderedThreadPoolExecutor()) {
            // use ordered thread pool, to ensure we process the events in order, and can send back
            // replies in the expected order. eg this is required by TCP.
            // and use a Camel thread factory so we have consistent thread namings
            String pattern = consumer.getContext().getExecutorServiceManager().getThreadNamePattern();
            ThreadFactory factory = new CamelThreadFactory(pattern, "NettyOrderedWorker", true);
            final ExecutionHandler executionHandler = new ExecutionHandler(
                    new OrderedMemoryAwareThreadPoolExecutor(consumer.getConfiguration().getMaximumPoolSize(),
                            0L, 0L, 30, TimeUnit.SECONDS, factory));
            // this must be added just before the ServerChannelHandler
            addToPipeline("executionHandler", channelPipeline, executionHandler);
View Full Code Here

TOP

Related Classes of org.apache.camel.util.concurrent.CamelThreadFactory

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.