public class BinaryHashTable extends BaseHybridHashTable
The design of this class follows in many parts the design presented in "Hash joins and hash teams in Microsoft SQL Server", by Goetz Graefe et al. In its current state, the implementation lacks features like dynamic role reversal, partition tuning, or histogram guided partitioning.
buildRowCount, buildSpillRetBufferNumbers, buildSpillReturnBuffers, closed, compressionBlockSize, compressionCodecFactory, compressionEnable, currentEnumerator, currentRecursionDepth, currentSpilledBuildSide, currentSpilledProbeSide, initPartitionFanOut, internalPool, ioManager, LOG, MAX_NUM_PARTITIONS, MAX_RECURSION_DEPTH, numSpillFiles, segmentSize, segmentSizeBits, segmentSizeMask, spillInBytes, totalNumBuffers, tryDistinctBuildRow| 构造器和说明 |
|---|
BinaryHashTable(org.apache.flink.configuration.Configuration conf,
Object owner,
AbstractRowDataSerializer buildSideSerializer,
AbstractRowDataSerializer probeSideSerializer,
Projection<org.apache.flink.table.data.RowData,org.apache.flink.table.data.binary.BinaryRowData> buildSideProjection,
Projection<org.apache.flink.table.data.RowData,org.apache.flink.table.data.binary.BinaryRowData> probeSideProjection,
org.apache.flink.runtime.memory.MemoryManager memManager,
long reservedMemorySize,
org.apache.flink.runtime.io.disk.iomanager.IOManager ioManager,
int avgRecordLen,
long buildRowCount,
boolean useBloomFilters,
HashJoinType type,
JoinCondition condFunc,
boolean reverseJoin,
boolean[] filterNulls,
boolean tryDistinctBuildRow) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
clearPartitions()
This method clears all partitions currently residing (partially) in memory.
|
void |
endBuild()
End build phase.
|
RowIterator<org.apache.flink.table.data.binary.BinaryRowData> |
getBuildSideIterator() |
org.apache.flink.table.data.RowData |
getCurrentProbeRow() |
boolean |
nextMatching()
Next record from rebuilt spilled partition or build side outer partition.
|
void |
putBuildRow(org.apache.flink.table.data.RowData row)
Put a build side row to hash table.
|
protected int |
spillPartition()
Selects a partition and spills it.
|
boolean |
tryProbe(org.apache.flink.table.data.RowData record)
Find matched build side rows for a probe row.
|
close, createInputView, ensureNumBuffersReturned, free, freeCurrent, freePages, getNextBuffer, getNextBuffers, getNotNullNextBuffer, getNumSpillFiles, getSpillInBytes, getUsedMemoryInBytes, hash, maxInitBufferOfBucketArea, maxNumPartition, nextSegment, pageSize, readAllBuffers, remainBuffers, returnAll, returnPagepublic BinaryHashTable(org.apache.flink.configuration.Configuration conf,
Object owner,
AbstractRowDataSerializer buildSideSerializer,
AbstractRowDataSerializer probeSideSerializer,
Projection<org.apache.flink.table.data.RowData,org.apache.flink.table.data.binary.BinaryRowData> buildSideProjection,
Projection<org.apache.flink.table.data.RowData,org.apache.flink.table.data.binary.BinaryRowData> probeSideProjection,
org.apache.flink.runtime.memory.MemoryManager memManager,
long reservedMemorySize,
org.apache.flink.runtime.io.disk.iomanager.IOManager ioManager,
int avgRecordLen,
long buildRowCount,
boolean useBloomFilters,
HashJoinType type,
JoinCondition condFunc,
boolean reverseJoin,
boolean[] filterNulls,
boolean tryDistinctBuildRow)
public void putBuildRow(org.apache.flink.table.data.RowData row)
throws IOException
IOExceptionpublic void endBuild()
throws IOException
IOExceptionpublic boolean tryProbe(org.apache.flink.table.data.RowData record)
throws IOException
IOExceptionpublic boolean nextMatching()
throws IOException
IOExceptionpublic org.apache.flink.table.data.RowData getCurrentProbeRow()
public RowIterator<org.apache.flink.table.data.binary.BinaryRowData> getBuildSideIterator()
public void clearPartitions()
This method is intended for a hard cleanup in the case that the join is aborted.
clearPartitions 在类中 BaseHybridHashTableprotected int spillPartition()
throws IOException
spillPartition 在类中 BaseHybridHashTableIOExceptionCopyright © 2014–2020 The Apache Software Foundation. All rights reserved.