@Internal public interface SplitAssigner
Modifier and Type | Method and Description |
---|---|
void |
addSplitsBack(List<PulsarPartitionSplit> splits,
int subtaskId)
Add a split back to the split assigner if the reader fails.
|
Optional<SplitsAssignment<PulsarPartitionSplit>> |
createAssignment(List<Integer> readers)
Create a split assignment from the current readers.
|
boolean |
noMoreSplits(Integer reader)
It would return true only if periodically partition discovery is turned off, the initializing
partition discovery has finished, AND there are no pending splits for assignment.
|
List<TopicPartition> |
registerTopicPartitions(Set<TopicPartition> fetchedPartitions)
Add the current available partitions into assigner.
|
PulsarSourceEnumState |
snapshotState()
Snapshot the current assign state into checkpoint.
|
List<TopicPartition> registerTopicPartitions(Set<TopicPartition> fetchedPartitions)
fetchedPartitions
- The available partitions queried from Pulsar broker.void addSplitsBack(List<PulsarPartitionSplit> splits, int subtaskId)
Optional<SplitsAssignment<PulsarPartitionSplit>> createAssignment(List<Integer> readers)
boolean noMoreSplits(Integer reader)
PulsarSourceEnumState snapshotState()
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.