public class OpaqueTridentEventHubEmitter extends Object implements IOpaquePartitionedTridentSpout.Emitter<Partitions,Partition,Map>
Constructor and Description |
---|
OpaqueTridentEventHubEmitter(EventHubSpoutConfig spoutConfig) |
OpaqueTridentEventHubEmitter(EventHubSpoutConfig spoutConfig,
int batchSize,
ITridentPartitionManagerFactory pmFactory,
IEventHubReceiverFactory recvFactory) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
Map |
emitPartitionBatch(TransactionAttempt attempt,
TridentCollector collector,
Partition partition,
Map meta)
Emit a batch of tuples for a partition/transaction.
|
List<Partition> |
getOrderedPartitions(Partitions partitions)
Sorts the partition info to produce an ordered list of partition.
|
void |
refreshPartitions(List<Partition> partitionList)
This method is called when this task is responsible for a new set of partitions.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getPartitionsForTask
public OpaqueTridentEventHubEmitter(EventHubSpoutConfig spoutConfig)
public OpaqueTridentEventHubEmitter(EventHubSpoutConfig spoutConfig, int batchSize, ITridentPartitionManagerFactory pmFactory, IEventHubReceiverFactory recvFactory)
public void close()
close
in interface IOpaquePartitionedTridentSpout.Emitter<Partitions,Partition,Map>
public Map emitPartitionBatch(TransactionAttempt attempt, TridentCollector collector, Partition partition, Map meta)
IOpaquePartitionedTridentSpout.Emitter
Return the metadata describing this batch that will be used as lastPartitionMeta for defining the parameters of the next batch.
emitPartitionBatch
in interface IOpaquePartitionedTridentSpout.Emitter<Partitions,Partition,Map>
public List<Partition> getOrderedPartitions(Partitions partitions)
IOpaquePartitionedTridentSpout.Emitter
getOrderedPartitions
in interface IOpaquePartitionedTridentSpout.Emitter<Partitions,Partition,Map>
partitions
- The partition info for all partitions being processed by all spout taskspublic void refreshPartitions(List<Partition> partitionList)
IOpaquePartitionedTridentSpout.Emitter
refreshPartitions
in interface IOpaquePartitionedTridentSpout.Emitter<Partitions,Partition,Map>
partitionList
- The partitions assigned to this taskCopyright © 2023 The Apache Software Foundation. All rights reserved.