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

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


            log.finest("initialize -configurationIdentifier:" + this.configurationIdentifier);
      }

      // could block quite a long time if the number of connections is big
      // or if the connection to the DB is slow.
      this.connections = new BoundedLinkedQueue();
      this.connections.setCapacity(this.capacity);
      try {
         // initializing and establishing of connections to DB (but first disconnect if already connected)
         final boolean disconnectFirst = true;
         connect(disconnectFirst, true);
View Full Code Here


            incoming_msg_handler=new IncomingMessageHandler();
            incoming_msg_handler.start();
        }

        if(use_outgoing_packet_handler) {
            outgoing_queue=new BoundedLinkedQueue(outgoing_queue_max_size);
            outgoing_packet_handler=new OutgoingPacketHandler();
            outgoing_packet_handler.start();
        }

        if(enable_bundling) {
View Full Code Here

   public BasicThreadPool(String name, ThreadGroup threadGroup)
   {
      trace = log.isTraceEnabled();
      ThreadFactory factory = new ThreadPoolThreadFactory();

      queue = new BoundedLinkedQueue(1024);

      executor = new MinPooledExecutor(queue, 100);
      executor.setMinimumPoolSize(100);
      executor.setKeepAliveTime(60 * 1000);
      executor.setThreadFactory(factory);
View Full Code Here

   public BasicThreadPool(String name, ThreadGroup threadGroup)
   {
      trace = log.isTraceEnabled();
      ThreadFactory factory = new ThreadPoolThreadFactory();

      queue = new BoundedLinkedQueue(1024);

      executor = new MinPooledExecutor(queue, 100);
      executor.setMinimumPoolSize(4);
      executor.setKeepAliveTime(60 * 1000);
      executor.setThreadFactory(factory);
View Full Code Here

        this.timout = timeout;
        Channel c;
        if (backLog <= 0) {
            c = new SynchronousChannel();
        } else {
            c = new BoundedLinkedQueue(backLog);
        }
        this.executor = new PooledExecutor(c, poolSize);
        this.executor.setMinimumPoolSize(poolSize);
        this.executor.setBlockedExecutionHandler(
                new PooledExecutor.BlockedExecutionHandler() {
View Full Code Here

        this.timout = timeout;
        Channel c;
        if (backLog <= 0) {
            c = new SynchronousChannel();
        } else {
            c = new BoundedLinkedQueue(backLog);
        }
        this.executor = new PooledExecutor(c, poolSize);
        this.executor.setMinimumPoolSize(poolSize);
        this.executor.setBlockedExecutionHandler(
                new PooledExecutor.BlockedExecutionHandler() {
View Full Code Here

        this.timout = timeout;
        Channel c;
        if (backLog <= 0) {
            c = new SynchronousChannel();
        } else {
            c = new BoundedLinkedQueue(backLog);
        }
        this.executor = new PooledExecutor(c, poolSize);
        this.executor.setMinimumPoolSize(poolSize);
        this.executor.setBlockedExecutionHandler(
                new PooledExecutor.BlockedExecutionHandler() {
View Full Code Here

        BoundedLinkedQueue queue;
        Protocol down;

        ProtocolBuffer(short size) {
            queue = new BoundedLinkedQueue(size);
        }
View Full Code Here

        BoundedLinkedQueue queue;
        Protocol down;

        ProtocolBuffer(short size) {
            queue = new BoundedLinkedQueue(size);
        }
View Full Code Here

      createQueue();
   }

   void createQueue()
   {
      nodeEventQueue_ = new BoundedLinkedQueue(RegionManager.CAPACITY);
   }
View Full Code Here

TOP

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

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.