TimestampedTupleForwarder¶
TimestampedTupleForwarder
is used by processors to determine whether or not to forward records to child nodes (downstream processors) (that happens only with no caching).
Creating Instance¶
TimestampedTupleForwarder
takes the following to be created:
- StateStore
- ProcessorContext
-
TimestampedCacheFlushListener
-
sendOldValues
flag
TimestampedTupleForwarder
is created when:
KStreamAggregateProcessor
is requested to initializeKStreamSlidingWindowAggregateProcessor
is requested to initializeKStreamWindowAggregateProcessor
is requested to initializeKTableSource
is requested to initialize- others
cachingEnabled Flag¶
TimestampedTupleForwarder
requests the StateStore to setFlushListener when created. The returned value is used to initialize cachingEnabled
internal flag for maybeForward.
maybeForward¶
void maybeForward(
K key,
V newValue,
V oldValue) // (1)
void maybeForward(
K key,
V newValue,
V oldValue,
long timestamp)
void maybeForward(
Record<K, Change<V>> record)
maybeForward
requests the InternalProcessorContext to forward a record only with the cachingEnabled flag disabled.