xmlBlaster 2.1.0 API

org.xmlBlaster.util.dispatch
Class DispatchWorkerPool

java.lang.Object
  extended by org.xmlBlaster.util.dispatch.DispatchWorkerPool

public class DispatchWorkerPool
extends java.lang.Object

Pool of threads doing a callback.


Nested Class Summary
protected static class DispatchWorkerPool.DeamonThreadFactory
           
 
Field Summary
private  PropInt createThreads
           
private  Global glob
           
private  boolean isShutdown
           
private static java.util.logging.Logger log
           
private  PropInt maximumPoolSize
           
 java.lang.String ME
           
private  java.util.concurrent.ThreadPoolExecutor pool
           
private  java.lang.String poolId
           
private  PropLong threadLifetime
           
private  PropInt threadPrio
           
 
Constructor Summary
DispatchWorkerPool(Global glob)
           
 
Method Summary
 boolean execute(java.lang.Runnable command)
           
 java.lang.String getName()
          A human readable name of the listener for logging.
 java.lang.String getStatistic()
           
private  void initialize()
           
 boolean isShutdown()
           
 void shutdown()
           
 void shutdownAfterProcessingCurrentlyQueuedTasks()
          A shut down pool cannot be restarted
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ME

public final java.lang.String ME
See Also:
Constant Field Values

glob

private Global glob

log

private static java.util.logging.Logger log

pool

private java.util.concurrent.ThreadPoolExecutor pool

threadPrio

private PropInt threadPrio

threadLifetime

private PropLong threadLifetime

maximumPoolSize

private PropInt maximumPoolSize

createThreads

private PropInt createThreads

isShutdown

private boolean isShutdown

poolId

private final java.lang.String poolId
See Also:
Constant Field Values
Constructor Detail

DispatchWorkerPool

public DispatchWorkerPool(Global glob)
Parameters:
maxWorkers - Maximum allowed callback threads
Method Detail

initialize

private void initialize()

isShutdown

public boolean isShutdown()

execute

public final boolean execute(java.lang.Runnable command)
                      throws java.lang.InterruptedException
Throws:
java.lang.InterruptedException

getStatistic

public java.lang.String getStatistic()

shutdownAfterProcessingCurrentlyQueuedTasks

public void shutdownAfterProcessingCurrentlyQueuedTasks()
A shut down pool cannot be restarted


shutdown

public void shutdown()

getName

public java.lang.String getName()
A human readable name of the listener for logging.

Enforced by I_RunlevelListener


xmlBlaster 2.1.0 API

Copyright © 1999-2011 The xmlBlaster.org contributers.