Package com.github.rholder.moar.concurrent.thread

Examples of com.github.rholder.moar.concurrent.thread.CallerBlocksPolicy


        ExecutorService workerExecutorService = StrategicExecutors.newBalancingThreadPoolExecutor(
                new ThreadPoolExecutor(
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_CORE),
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_MAX),
                        1, TimeUnit.MINUTES,
                        new SynchronousQueue<Runnable>(), new CallerBlocksPolicy()
                ),
                configuration.getFloat(QSConfig.PROP_WORKER_POOL_UTILIZATION), DEFAULT_SMOOTHING_WEIGHT, DEFAULT_BALANCE_AFTER
        );

        return new QueueReader<TaskHandle, TaskHandle, Object>(
View Full Code Here


        ExecutorService workerExecutorService = StrategicExecutors.newBalancingThreadPoolExecutor(
                new ThreadPoolExecutor(
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_CORE),
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_MAX),
                        1, TimeUnit.MINUTES,
                        new SynchronousQueue<Runnable>(), new CallerBlocksPolicy()
                ),
                configuration.getFloat(QSConfig.PROP_WORKER_POOL_UTILIZATION), DEFAULT_SMOOTHING_WEIGHT, DEFAULT_BALANCE_AFTER
        );

        return new QueueReader<QSTaskModel, TaskKit, Object>(
View Full Code Here

        ExecutorService workerExecutorService = StrategicExecutors.newBalancingThreadPoolExecutor(
                new ThreadPoolExecutor(
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_CORE),
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_MAX),
                        1, TimeUnit.MINUTES,
                        new SynchronousQueue<Runnable>(), new CallerBlocksPolicy()
                ),
                configuration.getFloat(QSConfig.PROP_WORKER_POOL_UTILIZATION), DEFAULT_SMOOTHING_WEIGHT, DEFAULT_BALANCE_AFTER
        );

        return new QueueReader<TaskHandle, TaskHandle, Object>(
View Full Code Here

        ExecutorService workerExecutorService = StrategicExecutors.newBalancingThreadPoolExecutor(
                new ThreadPoolExecutor(
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_CORE),
                        configuration.getInt(QSConfig.PROP_WORKER_POOL_MAX),
                        1, TimeUnit.MINUTES,
                        new SynchronousQueue<Runnable>(), new CallerBlocksPolicy()
                ),
                configuration.getFloat(QSConfig.PROP_WORKER_POOL_UTILIZATION), DEFAULT_SMOOTHING_WEIGHT, DEFAULT_BALANCE_AFTER
        );

        return new QueueReader<QSTaskModel, TaskKit<Object>, Object>(
View Full Code Here

TOP

Related Classes of com.github.rholder.moar.concurrent.thread.CallerBlocksPolicy

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.