public class IndependentIterationsThreadPoolStage<T> extends AbstractEStage<List<T>>
| Constructor and Description |
|---|
IndependentIterationsThreadPoolStage(EventHandler<T> handler,
int numThreads,
int granularity)
Create a thread pool with fixed threads.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
onNext(List<T> iterations)
Handles an event.
|
getInMeter, getOutMeter, isClosed, toStringpublic IndependentIterationsThreadPoolStage(EventHandler<T> handler, int numThreads, int granularity)
handler - an event handlernumThreads - fixed number of threads available in the poolgranularity - maximum number of events executed serially.
The right choice will balance task spawn overhead with parallelism.Copyright © 2017 The Apache Software Foundation. All rights reserved.