Class SimpleFetcherBolt

  • All Implemented Interfaces:
    Serializable, org.apache.storm.task.IBolt, org.apache.storm.topology.IComponent, org.apache.storm.topology.IRichBolt

    public class SimpleFetcherBolt
    extends StatusEmitterBolt
    A simple fetcher with no internal queues. This bolt either enforces the delay set by the configuration or robots.txt by either sleeping or resending the tuple to itself on the THROTTLE_STREAM using Direct grouping.
     .directGrouping("fetch", "throttle")
     
    See Also:
    Serialized Form
    • Constructor Detail

      • SimpleFetcherBolt

        public SimpleFetcherBolt()
    • Method Detail

      • prepare

        public void prepare​(Map<String,​Object> stormConf,
                            org.apache.storm.task.TopologyContext context,
                            org.apache.storm.task.OutputCollector collector)
        Specified by:
        prepare in interface org.apache.storm.task.IBolt
        Overrides:
        prepare in class StatusEmitterBolt
      • declareOutputFields

        public void declareOutputFields​(org.apache.storm.topology.OutputFieldsDeclarer declarer)
        Specified by:
        declareOutputFields in interface org.apache.storm.topology.IComponent
        Overrides:
        declareOutputFields in class StatusEmitterBolt
      • cleanup

        public void cleanup()
        Specified by:
        cleanup in interface org.apache.storm.task.IBolt
        Overrides:
        cleanup in class org.apache.storm.topology.base.BaseRichBolt
      • execute

        public void execute​(org.apache.storm.tuple.Tuple input)