public class WorkloadExecutor extends Object
| Constructor and Description |
|---|
WorkloadExecutor() |
WorkloadExecutor(Properties properties) |
WorkloadExecutor(Properties properties,
List<Workload> workloads) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(Workload workload) |
void |
complete()
Complete all workloads in the list.
|
void |
get()
Blocks on waiting for all workloads to finish.
|
void |
get(Workload workload)
Calls the
Future.get() method pertaining to this workflow. |
ExecutorService |
getPool() |
void |
shutdown() |
public WorkloadExecutor(Properties properties) throws Exception
Exceptionpublic WorkloadExecutor(Properties properties, List<Workload> workloads) throws Exception
Exceptionpublic void get()
Workload Requires complete() to be called, it must
be called prior to using this method. Otherwise it will block infinitely.public void get(Workload workload)
Future.get() method pertaining to this workflow.
Once the Future competes, the workflow is removed from the list.workload - Key entry in the HashMappublic void complete()
public void shutdown()
public ExecutorService getPool()
Copyright © 2015 Apache Software Foundation. All Rights Reserved.