public static class SlidingWindowTopology.SlidingWindowBolt extends BaseWindowedBolt
BaseWindowedBolt.Count, BaseWindowedBolt.Duration
timestampExtractor, windowConfiguration
Constructor and Description |
---|
SlidingWindowBolt() |
Modifier and Type | Method and Description |
---|---|
void |
declareOutputFields(OutputFieldsDeclarer declarer)
Declare the output schema for all the streams of this topology.
|
void |
execute(TupleWindow inputWindow)
Process the tuple window and optionally emit new tuples based on the tuples in the input
window.
|
void |
prepare(java.util.Map conf,
TopologyContext context,
OutputCollector collector)
This is similar to the
IBolt.prepare(Map, TopologyContext, OutputCollector) except
that while emitting, the tuples are automatically anchored to the tuples in the inputWindow. |
cleanup, getComponentConfiguration, getTimestampExtractor, withLag, withLateTupleStream, withTimestampExtractor, withTimestampField, withTumblingWindow, withTumblingWindow, withWatermarkInterval, withWindow, withWindow, withWindow, withWindow, withWindow, withWindow
public void prepare(java.util.Map conf, TopologyContext context, OutputCollector collector)
IWindowedBolt
IBolt.prepare(Map, TopologyContext, OutputCollector)
except
that while emitting, the tuples are automatically anchored to the tuples in the inputWindow.prepare
in interface IWindowedBolt
prepare
in class BaseWindowedBolt
public void execute(TupleWindow inputWindow)
IWindowedBolt
public void declareOutputFields(OutputFieldsDeclarer declarer)
IComponent
declareOutputFields
in interface IComponent
declareOutputFields
in class BaseWindowedBolt
declarer
- this is used to declare output stream ids, output fields, and whether or not each output stream is a direct stream