Package org.apache.servicemix.executors.impl

Examples of org.apache.servicemix.executors.impl.ExecutorConfig


     * based on the default configuration used in ServiceMix 4
     */
    protected ExecutorFactory createExecutorFactory() {
        ExecutorFactoryImpl factory = new ExecutorFactoryImpl();

        ExecutorConfig config = factory.getDefaultConfig();
        config.setCorePoolSize(1);
        config.setMaximumPoolSize(16);
        config.setQueueSize(0);
        config.setBypassIfSynchronous(true);

        return factory;
    };
View Full Code Here


        this.executorFactory = factory;
    }

    public void updated(Dictionary properties) throws ConfigurationException {
        if (executorFactory.getDefaultConfig() == null) {
            executorFactory.setDefaultConfig(new ExecutorConfig(true, null));
        }
        Map<String, ExecutorConfig> configs = new HashMap<String, ExecutorConfig>();
        if (properties != null) {
            for (Enumeration e = properties.keys(); e.hasMoreElements();) {
                String key = (String) e.nextElement();
View Full Code Here

        executorFactory.setConfigs(configs);
    }

    private ExecutorConfig getConfig(Map<String, ExecutorConfig> configs, String key) {
        String name = key.substring(0, key.lastIndexOf('.'));
        ExecutorConfig config = configs.get(name);
        if (config == null) {
            config = new ExecutorConfig(false, executorFactory.getDefaultConfig());
            configs.put(name, config);
        }
        return config;
    }
View Full Code Here

     * based on the default configuration used in ServiceMix 4
     */
    protected ExecutorFactory createExecutorFactory() {
        ExecutorFactoryImpl factory = new ExecutorFactoryImpl();

        ExecutorConfig config = factory.getDefaultConfig();
        config.setCorePoolSize(1);
        config.setMaximumPoolSize(16);
        config.setQueueSize(0);
        config.setBypassIfSynchronous(true);

        return factory;
    };
View Full Code Here

TOP

Related Classes of org.apache.servicemix.executors.impl.ExecutorConfig

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.