cascading.management
Class UnitOfWorkExecutorStrategy
java.lang.Object
cascading.management.UnitOfWorkExecutorStrategy
- All Implemented Interfaces:
- UnitOfWorkSpawnStrategy
public class UnitOfWorkExecutorStrategy
- extends Object
- implements UnitOfWorkSpawnStrategy
Class UnitOfWorkExecutorStrategy uses a simple Executors.newFixedThreadPool(int)
ExecutorService
to spawn threads.
This is the default spawn strategy.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UnitOfWorkExecutorStrategy
public UnitOfWorkExecutorStrategy()
start
public List<Future<Throwable>> start(UnitOfWork unitOfWork,
int maxConcurrentThreads,
Collection<Callable<Throwable>> values)
throws InterruptedException
- Specified by:
start
in interface UnitOfWorkSpawnStrategy
- Throws:
InterruptedException
isCompleted
public boolean isCompleted(UnitOfWork unitOfWork)
- Specified by:
isCompleted
in interface UnitOfWorkSpawnStrategy
complete
public void complete(UnitOfWork unitOfWork,
int duration,
TimeUnit unit)
throws InterruptedException
- Specified by:
complete
in interface UnitOfWorkSpawnStrategy
- Throws:
InterruptedException
Copyright © 2007-2013 Concurrent, Inc. All Rights Reserved.