public class NullTerminatingSpout extends Object implements FiniteSpout
NullTerminatingSpout in a finite spout (ie, implements FiniteSpout interface) that wraps an
infinite spout, and returns true in reachedEnd() when the wrapped spout does not emit a tuple
in nextTuple() for the first time.| Constructor and Description |
|---|
NullTerminatingSpout(backtype.storm.topology.IRichSpout spout) |
| Modifier and Type | Method and Description |
|---|---|
void |
ack(Object msgId) |
void |
activate() |
void |
close() |
void |
deactivate() |
void |
declareOutputFields(backtype.storm.topology.OutputFieldsDeclarer declarer) |
void |
fail(Object msgId) |
Map<String,Object> |
getComponentConfiguration() |
void |
nextTuple() |
void |
open(Map conf,
backtype.storm.task.TopologyContext context,
backtype.storm.spout.SpoutOutputCollector collector) |
boolean |
reachedEnd()
When returns true, the spout has reached the end of the stream.
|
public NullTerminatingSpout(backtype.storm.topology.IRichSpout spout)
public void open(Map conf, backtype.storm.task.TopologyContext context, backtype.storm.spout.SpoutOutputCollector collector)
open in interface backtype.storm.spout.ISpoutpublic void close()
close in interface backtype.storm.spout.ISpoutpublic void activate()
activate in interface backtype.storm.spout.ISpoutpublic void deactivate()
deactivate in interface backtype.storm.spout.ISpoutpublic void nextTuple()
nextTuple in interface backtype.storm.spout.ISpoutpublic void ack(Object msgId)
ack in interface backtype.storm.spout.ISpoutpublic void fail(Object msgId)
fail in interface backtype.storm.spout.ISpoutpublic void declareOutputFields(backtype.storm.topology.OutputFieldsDeclarer declarer)
declareOutputFields in interface backtype.storm.topology.IComponentpublic Map<String,Object> getComponentConfiguration()
getComponentConfiguration in interface backtype.storm.topology.IComponentpublic boolean reachedEnd()
FiniteSpoutreachedEnd in interface FiniteSpoutCopyright © 2014–2016 The Apache Software Foundation. All rights reserved.