@Internal public interface SplitAssigner extends Serializable
| 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<org.apache.flink.api.connector.source.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 disabled, the initializing
partition discovery has finished AND there is 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<org.apache.flink.api.connector.source.SplitsAssignment<PulsarPartitionSplit>> createAssignment(List<Integer> readers)
boolean noMoreSplits(Integer reader)
PulsarSourceEnumState snapshotState()
Copyright © 2014–2022 The Apache Software Foundation. All rights reserved.