public class Forker extends Object
RecordStreamWithMetadata into multiple branches specified by a ForkOperator.
Each forked stream is a mirror of the original stream.| Modifier and Type | Class and Description |
|---|---|
static class |
Forker.ForkedStream<D,S>
An object containing the forked streams and a
ConnectableFlowable used to connect the stream when all
streams have been subscribed to. |
| Constructor and Description |
|---|
Forker() |
| Modifier and Type | Method and Description |
|---|---|
<D,S> Forker.ForkedStream<D,S> |
forkStream(RecordStreamWithMetadata<D,S> inputStream,
ForkOperator<S,D> forkOperator,
WorkUnitState workUnitState)
|
public <D,S> Forker.ForkedStream<D,S> forkStream(RecordStreamWithMetadata<D,S> inputStream, ForkOperator<S,D> forkOperator, WorkUnitState workUnitState) throws Exception
inputStream - input Flowable of records.forkOperator - ForkOperator specifying the fork behavior.workUnitState - work unit configuration.Forker.ForkedStream with the forked streams.Exception - if the ForkOperator throws any exceptions.