void writeToTopology(
InternalTopologyBuilder topologyBuilder)
StatefulProcessorNode
StatefulProcessorNode
is a concrete StreamsGraphNode (as a ProcessorGraphNode) that represents stateful operators of the following:
StatefulProcessorNode
is created when:
-
KStreamImpl
is requested to KStreamImpl.transform and KStreamImpl.flatTransform, KStreamImpl.transformValues, KStreamImpl.flatTransformValues, KStreamImpl.process -
GroupedStreamAggregateBuilder
is requested to build (for KStream.groupBy and KStream.groupByKey streaming operators, incl.windowedBy
operator with a Windows or a SessionWindows) -
KGroupedTableImpl
is requested to doAggregate (for KGroupedTableImpl.aggregate, KGroupedTableImpl.count, and KGroupedTableImpl.reduce operators) -
KTableImpl
is requested to suppress
StatefulProcessorNode
extends the parent ProcessorGraphNode with the two state-related parameters - the state store names and a StoreBuilder.
Creating StatefulProcessorNode Instance
StatefulProcessorNode
takes the following to be created:
-
Names of the state stores or a StoreBuilder
writeToTopology
Method
Note
|
writeToTopology is part of the StreamsGraphNode Contract to…FIXME.
|
writeToTopology
requests the given InternalTopologyBuilder to add a processor (with the name and the ProcessorSupplier as defined by the ProcessorParameters).
With state store names given, writeToTopology
requests the given InternalTopologyBuilder
to connect them with the processor.
With a StoreBuilder given, writeToTopology
requests the given InternalTopologyBuilder
to add a state store (with the StoreBuilder
and the processor).