public static class TridentEsTopology.FixedBatchSpout extends Object implements IBatchSpout
Constructor and Description |
---|
FixedBatchSpout(int maxBatchSizeArg)
Creates a new fixed batch spout.
|
Modifier and Type | Method and Description |
---|---|
void |
ack(long batchId)
Acknowledges the message with id
msgId . |
void |
close()
Closes the spout.
|
void |
emitBatch(long batchId,
TridentCollector collector)
Emits a batch.
|
Map<String,Object> |
getComponentConfiguration()
Get the component configuration.
|
Fields |
getOutputFields()
Gets the output fields.
|
void |
open(Map<String,Object> conf,
TopologyContext context)
Opens the spout.
|
public FixedBatchSpout(int maxBatchSizeArg)
maxBatchSizeArg
- the maximum batch size to setpublic Fields getOutputFields()
getOutputFields
in interface IBatchSpout
public void open(Map<String,Object> conf, TopologyContext context)
open
in interface IBatchSpout
conf
- the configuration to use for openingcontext
- the context to use for openingpublic void emitBatch(long batchId, TridentCollector collector)
emitBatch
in interface IBatchSpout
batchId
- the batch id to usecollector
- the collector to emit topublic void ack(long batchId)
msgId
.ack
in interface IBatchSpout
batchId
- the message idpublic void close()
close
in interface IBatchSpout
public Map<String,Object> getComponentConfiguration()
getComponentConfiguration
in interface IBatchSpout
Copyright © 2023 The Apache Software Foundation. All rights reserved.