Class HeapWindowsGrouping
- java.lang.Object
-
- org.apache.flink.table.runtime.operators.window.grouping.WindowsGrouping
-
- org.apache.flink.table.runtime.operators.window.grouping.HeapWindowsGrouping
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
public class HeapWindowsGrouping extends WindowsGrouping
A jvm heap implementation ofWindowsGrouping
, which uses a linked list to buffer all the inputs of a keyed group belonging to the same window. It is designed to have a capacity limit to avoid JVM OOM and reduce GC pauses.
-
-
Constructor Summary
Constructors Constructor Description HeapWindowsGrouping(int maxSizeLimit, long windowSize, long slideSize, int timeIndex, boolean isDate)
HeapWindowsGrouping(int maxSizeLimit, long offset, long windowSize, long slideSize, int timeIndex, boolean isDate)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addIntoBuffer(BinaryRowData input)
void
close()
protected RowIterator<BinaryRowData>
newBufferIterator(int startIndex)
protected void
onBufferEvict(int limitIndex)
protected void
resetBuffer()
-
Methods inherited from class org.apache.flink.table.runtime.operators.window.grouping.WindowsGrouping
addInputToBuffer, advanceWatermarkToTriggerAllWindows, buildTriggerWindowElementsIterator, getTriggerWindow, hasTriggerWindow, reset
-
-
-
-
Method Detail
-
resetBuffer
protected void resetBuffer()
- Specified by:
resetBuffer
in classWindowsGrouping
-
onBufferEvict
protected void onBufferEvict(int limitIndex)
- Specified by:
onBufferEvict
in classWindowsGrouping
-
addIntoBuffer
protected void addIntoBuffer(BinaryRowData input) throws IOException
- Specified by:
addIntoBuffer
in classWindowsGrouping
- Throws:
IOException
-
newBufferIterator
protected RowIterator<BinaryRowData> newBufferIterator(int startIndex)
- Specified by:
newBufferIterator
in classWindowsGrouping
-
close
public void close() throws IOException
- Throws:
IOException
-
-