Class BinaryExternalMerger
java.lang.Object
org.apache.flink.table.runtime.operators.sort.AbstractBinaryExternalMerger<org.apache.flink.table.data.binary.BinaryRowData>
org.apache.flink.table.runtime.operators.sort.BinaryExternalMerger
- All Implemented Interfaces:
Closeable,AutoCloseable
public class BinaryExternalMerger
extends AbstractBinaryExternalMerger<org.apache.flink.table.data.binary.BinaryRowData>
Record merger for sort of BinaryRowData.
-
Field Summary
Fields inherited from class org.apache.flink.table.runtime.operators.sort.AbstractBinaryExternalMerger
ioManager, pageSize -
Constructor Summary
ConstructorsConstructorDescriptionBinaryExternalMerger(org.apache.flink.runtime.io.disk.iomanager.IOManager ioManager, int pageSize, int maxFanIn, SpillChannelManager channelManager, BinaryRowDataSerializer serializer, RecordComparator comparator, boolean compressionEnabled, org.apache.flink.runtime.io.compression.BlockCompressionFactory compressionCodecFactory, int compressionBlockSize) -
Method Summary
Modifier and TypeMethodDescriptionprotected org.apache.flink.util.MutableObjectIterator<org.apache.flink.table.data.binary.BinaryRowData>channelReaderInputViewIterator(org.apache.flink.runtime.io.disk.iomanager.AbstractChannelReaderInputView inView) protected Comparator<org.apache.flink.table.data.binary.BinaryRowData>protected List<org.apache.flink.table.data.binary.BinaryRowData>mergeReusedEntries(int size) protected voidwriteMergingOutput(org.apache.flink.util.MutableObjectIterator<org.apache.flink.table.data.binary.BinaryRowData> mergeIterator, org.apache.flink.runtime.memory.AbstractPagedOutputView output) read the merged stream and write the data back.Methods inherited from class org.apache.flink.table.runtime.operators.sort.AbstractBinaryExternalMerger
close, getMergingIterator, mergeChannelList
-
Constructor Details
-
BinaryExternalMerger
public BinaryExternalMerger(org.apache.flink.runtime.io.disk.iomanager.IOManager ioManager, int pageSize, int maxFanIn, SpillChannelManager channelManager, BinaryRowDataSerializer serializer, RecordComparator comparator, boolean compressionEnabled, org.apache.flink.runtime.io.compression.BlockCompressionFactory compressionCodecFactory, int compressionBlockSize)
-
-
Method Details
-
channelReaderInputViewIterator
protected org.apache.flink.util.MutableObjectIterator<org.apache.flink.table.data.binary.BinaryRowData> channelReaderInputViewIterator(org.apache.flink.runtime.io.disk.iomanager.AbstractChannelReaderInputView inView) - Specified by:
channelReaderInputViewIteratorin classAbstractBinaryExternalMerger<org.apache.flink.table.data.binary.BinaryRowData>- Returns:
- entry iterator reading from inView.
-
mergeComparator
- Specified by:
mergeComparatorin classAbstractBinaryExternalMerger<org.apache.flink.table.data.binary.BinaryRowData>- Returns:
- merging comparator used in merging.
-
mergeReusedEntries
- Specified by:
mergeReusedEntriesin classAbstractBinaryExternalMerger<org.apache.flink.table.data.binary.BinaryRowData>- Returns:
- reused entry object used in merging.
-
writeMergingOutput
protected void writeMergingOutput(org.apache.flink.util.MutableObjectIterator<org.apache.flink.table.data.binary.BinaryRowData> mergeIterator, org.apache.flink.runtime.memory.AbstractPagedOutputView output) throws IOException Description copied from class:AbstractBinaryExternalMergerread the merged stream and write the data back.- Specified by:
writeMergingOutputin classAbstractBinaryExternalMerger<org.apache.flink.table.data.binary.BinaryRowData>- Throws:
IOException
-