Package java.util.concurrent

Examples of java.util.concurrent.LinkedBlockingQueue$LBQSpliterator


        }
        return result;
    }
   
    private LinkedBlockingQueue getNewQueue() {
        return new LinkedBlockingQueue();
    }   
View Full Code Here


            _pipelogger.finest("initializePool - pool size: " + poolSize);
        }
        if(poolSize == 0) {
            //return;
            //_pool = new BoundedLinkedQueue(10);
            _pool = new LinkedBlockingQueue(10);
        } else {
            //_pool = new BoundedLinkedQueue(poolSize);
            _pool = new LinkedBlockingQueue(poolSize);
        }
        for(int i=0; i<poolSize; i++) {
            PipePoolElement nextPipeWrapper = (PipePoolElement)pipeWrappers.get(i);
            try
            {
View Full Code Here

            _pipelogger.finest("initializePool - pool size: " + poolSize);
        }
        if(poolSize == 0) {
            //return;
            //_pool = new BoundedLinkedQueue(10);
            _pool = new LinkedBlockingQueue(10);
        } else {
            //_pool = new BoundedLinkedQueue(poolSize);
            _pool = new LinkedBlockingQueue(poolSize);
        }
    }        
View Full Code Here

    private void initializePool(int poolSize) {
        if(_storeFactory == null) {
            return;
        }
        //_pool = new BoundedLinkedQueue(poolSize);
        _pool = new LinkedBlockingQueue(poolSize);
        for(int i=0; i<poolSize; i++) {
            StorePoolElement nextStore = _storeFactory.createHAStore();
            try
            {
                if(_logger.isLoggable(Level.FINEST)) {
View Full Code Here

        _arguments = arguments;
        _prefetchHigh = prefetchHigh;
        _prefetchLow = prefetchLow;
        _exclusive = exclusive;
       
        _synchronousQueue = new LinkedBlockingQueue();
        _autoClose = autoClose;
        _noConsume = noConsume;

        // Force queue browsers not to use acknowledge modes.
        if (_noConsume)
View Full Code Here

        _session = session;
        _prefetchHigh = prefetchHigh;
        _prefetchLow = prefetchLow;
        _exclusive = exclusive;
       
        _synchronousQueue = new LinkedBlockingQueue();
        _autoClose = autoClose;
        _browseOnly = browseOnly;

        try
        {
View Full Code Here

        if (!threadPoolEnabled)
            return new NonParallelExecutor();

        final ThreadPoolExecutor executorService = new ThreadPoolExecutor(coreSize, maxSize, keepAliveMillis,
                TimeUnit.MILLISECONDS, new LinkedBlockingQueue());

        shutdownHub.addRegistryShutdownListener(new RegistryShutdownListener()
        {
            public void registryDidShutdown()
            {
View Full Code Here

    private final Executor executor;

    public ServicePool(ServerService next, final String name, final int threads, final long keepAliveTime) {
        this.next = next;

        ThreadPoolExecutor p = new ThreadPoolExecutor(threads, threads, keepAliveTime, TimeUnit.MILLISECONDS, new LinkedBlockingQueue());
        p.setThreadFactory(new ThreadFactory() {
            private volatile int id = 0;

            public Thread newThread(Runnable arg0) {
                Thread thread = new Thread(arg0, name + " " + getNextID());
View Full Code Here

        _arguments = arguments;
        _prefetchHigh = prefetchHigh;
        _prefetchLow = prefetchLow;
        _exclusive = exclusive;

        _synchronousQueue = new LinkedBlockingQueue();
        _autoClose = autoClose;
        _noConsume = noConsume;

        // Force queue browsers not to use acknowledge modes.
        if (_noConsume)
View Full Code Here

public class SedaConfigureTest extends ContextTestSupport {

    public void testBlockingQueueConfigured() throws Exception {
        SedaEndpoint endpoint = resolveMandatoryEndpoint("seda:foo?size=2000", SedaEndpoint.class);
        BlockingQueue<Exchange> queue = endpoint.getQueue();
        LinkedBlockingQueue blockingQueue = assertIsInstanceOf(LinkedBlockingQueue.class, queue);
        assertEquals("remainingCapacity", 2000, blockingQueue.remainingCapacity());
    }
View Full Code Here

TOP

Related Classes of java.util.concurrent.LinkedBlockingQueue$LBQSpliterator

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.