Package org.apache.storm.starter.spout
Class RandomNumberGeneratorSpout
java.lang.Object
org.apache.storm.starter.spout.RandomNumberGeneratorSpout
- All Implemented Interfaces:
Serializable,IBatchSpout,ITridentDataSource
This spout generates random whole numbers with given
maxNumber value as maximum with the given fields.- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidack(long batchId) voidclose()voidemitBatch(long batchId, TridentCollector collector) voidopen(Map<String, Object> conf, TopologyContext context)
-
Constructor Details
-
RandomNumberGeneratorSpout
-
-
Method Details
-
open
- Specified by:
openin interfaceIBatchSpout
-
emitBatch
- Specified by:
emitBatchin interfaceIBatchSpout
-
ack
public void ack(long batchId) - Specified by:
ackin interfaceIBatchSpout
-
close
public void close()- Specified by:
closein interfaceIBatchSpout
-
getComponentConfiguration
- Specified by:
getComponentConfigurationin interfaceIBatchSpout
-
getOutputFields
- Specified by:
getOutputFieldsin interfaceIBatchSpout
-