Package EDU.oswego.cs.dl.util.concurrent

Examples of EDU.oswego.cs.dl.util.concurrent.LinkedQueue


        if (useQueueing) {
            if (queueSize > 0) {
                this.executor = new PooledExecutor(new BoundedBuffer(queueSize));
            } else {
                this.executor = new PooledExecutor(new LinkedQueue());
            }
        } else {
            this.executor = new PooledExecutor();
        }
View Full Code Here


        {
            if ( log.isDebugEnabled() )
            {
                log.debug( "Creating a non bounded Linked Queue to use for the pool" );
            }
            queue = new LinkedQueue();
            pool = new PooledExecutor( queue, config.getMaximumPoolSize() );
        }

        pool.setMinimumPoolSize( config.getMinimumPoolSize() );
        pool.setKeepAliveTime( config.getKeepAliveTime() );
View Full Code Here

        if (useQueueing) {
            if (queueSize > 0) {
                m_executor = new PooledExecutor(new BoundedBuffer(queueSize));
            } else {
                m_executor = new PooledExecutor(new LinkedQueue());
            }
        } else {
            m_executor = new PooledExecutor();
        }
View Full Code Here

     * one.
     *
     * @param maxSize Maximum size of the work executor pool.
     */
    public WorkExecutorPoolImpl(int maxSize) {
        pooledExecutor = new PooledExecutor(new LinkedQueue(), maxSize);
        pooledExecutor.setMinimumPoolSize(maxSize);
        pooledExecutor.waitWhenBlocked();
    }
View Full Code Here

    private int logFileSize=1024*1024*20;
    private int logFileCount=2;
    private long checkpointInterval = 1000 * 60 * 5;

    public JournalPersistenceAdapter() {
        checkpointExecutor = new QueuedExecutor(new LinkedQueue());
        checkpointExecutor.setThreadFactory(new ThreadFactory() {
            public Thread newThread(Runnable runnable) {
                Thread answer = new Thread(runnable, "Checkpoint Worker");
                answer.setDaemon(true);
                answer.setPriority(Thread.MAX_PRIORITY);
View Full Code Here

        final int threadPoolInitSize,

        final int keepAliveTime) {

        m_threadPool = new PooledExecutor(new LinkedQueue());

        m_threadPool.setKeepAliveTime(keepAliveTime);

        m_threadPool.createThreads(threadPoolInitSize);
View Full Code Here

      long threadKeepAliveTime, boolean unlimitedQueue, URL resUrl) {

    this.instRep = instRep;
    Channel c = null;
    if (unlimitedQueue) {
      c = new LinkedQueue();
    } else {
      c = new BoundedBuffer(queueSize);
    }

    pool = new PooledExecutor(c, maxPoolSize);
View Full Code Here

         leftSet = new ConcurrentHashSet();
      }
     
      //NOTE, MUST be a QueuedExecutor so we ensure that responses arrive back in order
      replyExecutor = new QueuedExecutor(new LinkedQueue());
     
      replicateResponseExecutor = new QueuedExecutor(new LinkedQueue());
   }
View Full Code Here

   public ConnectionFactoryJNDIMapper(ServerPeer serverPeer) throws Exception
   {
      this.serverPeer = serverPeer;
      endpoints = new HashMap();
      delegates = new HashMap();         
      notifyExecutor = new QueuedExecutor(new LinkedQueue());
   }
View Full Code Here

      {
         // Create a local tx
         currentTxId = parent.getResourceManager().createLocalTx();
      }

      executor = new JBMExecutor(new LinkedQueue());

      clientAckList = new ArrayList();

      // TODO could optimise this to use the same map of callbackmanagers (which holds refs
      // to callbackhandlers) in the connection, instead of maintaining another map
View Full Code Here

TOP

Related Classes of EDU.oswego.cs.dl.util.concurrent.LinkedQueue

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.