org.compass.core.executor
Interface ExecutorManager

All Superinterfaces:
InternalExecutorManager
All Known Implementing Classes:
DefaultExecutorManager

public interface ExecutorManager
extends InternalExecutorManager

An executor manager is an abstraction on top of async and scheduled execution of tasks.

Author:
kimchy

Method Summary
<T> List<Future<T>>
invokeAllWithLimit(Collection<Callable<T>> tasks, int concurrencyThreshold)
          Similar to InternalExecutorManager.invokeAll(java.util.Collection), but only uses it if the number of tasks passes the concurrent limit.
<T> List<Future<T>>
invokeAllWithLimitBailOnException(Collection<Callable<T>> tasks, int concurrencyThreshold)
          Similar to invokeAllWithLimit(java.util.Collection, int), but if one task throws an exception will propogate the exception.
 
Methods inherited from interface org.compass.core.executor.spi.InternalExecutorManager
close, invokeAll, schedule, scheduleAtFixedRate, scheduleWithFixedDelay, submit, submit
 

Method Detail

invokeAllWithLimit

<T> List<Future<T>> invokeAllWithLimit(Collection<Callable<T>> tasks,
                                       int concurrencyThreshold)
Similar to InternalExecutorManager.invokeAll(java.util.Collection), but only uses it if the number of tasks passes the concurrent limit.


invokeAllWithLimitBailOnException

<T> List<Future<T>> invokeAllWithLimitBailOnException(Collection<Callable<T>> tasks,
                                                      int concurrencyThreshold)
Similar to invokeAllWithLimit(java.util.Collection, int), but if one task throws an exception will propogate the exception.



Copyright (c) 2004-2009 The Compass Project.