Class SimpleSplitAssigner
java.lang.Object
org.apache.flink.connector.file.src.assigners.SimpleSplitAssigner
- All Implemented Interfaces:
FileSplitAssigner
The
SimpleSplitAssigner hands out splits in a random order, without any consideration for
order or locality.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.flink.connector.file.src.assigners.FileSplitAssigner
FileSplitAssigner.Provider -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddSplits(Collection<FileSourceSplit> newSplits) Adds a set of splits to this assigner.Gets the next split.Gets the remaining splits that this assigner has pending.toString()
-
Constructor Details
-
SimpleSplitAssigner
-
-
Method Details
-
getNext
Description copied from interface:FileSplitAssignerGets the next split.When this method returns an empty
Optional, then the set of splits is assumed to be done and the source will finish once the readers finished their current splits.- Specified by:
getNextin interfaceFileSplitAssigner
-
addSplits
Description copied from interface:FileSplitAssignerAdds a set of splits to this assigner. This happens for example when some split processing failed and the splits need to be re-added, or when new splits got discovered.- Specified by:
addSplitsin interfaceFileSplitAssigner
-
remainingSplits
Description copied from interface:FileSplitAssignerGets the remaining splits that this assigner has pending.- Specified by:
remainingSplitsin interfaceFileSplitAssigner
-
toString
-