W
- The type of Window
that assigner assigns.public class PanedWindowProcessFunction<K,W extends Window> extends InternalWindowProcessFunction<K,W>
InternalWindowProcessFunction
for PanedWindowAssigner
.InternalWindowProcessFunction.Context<K,W extends Window>
allowedLateness, ctx, windowAggregator
Constructor and Description |
---|
PanedWindowProcessFunction(PanedWindowAssigner<W> windowAssigner,
NamespaceAggsHandleFunctionBase<W> windowAggregator,
long allowedLateness) |
Modifier and Type | Method and Description |
---|---|
Collection<W> |
assignActualWindows(RowData inputRow,
long timestamp)
Assigns the input element into the actual windows which the
Trigger should trigger
on. |
Collection<W> |
assignStateNamespace(RowData inputRow,
long timestamp)
Assigns the input element into the state namespace which the input element should be
accumulated/retracted into.
|
void |
cleanWindowIfNeeded(W window,
long currentTime)
Cleans the given window if needed.
|
void |
prepareAggregateAccumulatorForEmit(W window)
Prepares the accumulator of the given window before emit the final result.
|
close, isCleanupTime, isWindowLate, open
public PanedWindowProcessFunction(PanedWindowAssigner<W> windowAssigner, NamespaceAggsHandleFunctionBase<W> windowAggregator, long allowedLateness)
public Collection<W> assignActualWindows(RowData inputRow, long timestamp) throws Exception
InternalWindowProcessFunction
Trigger
should trigger
on.assignActualWindows
in class InternalWindowProcessFunction<K,W extends Window>
inputRow
- the input elementtimestamp
- the timestamp of the element or the processing time (depends on the type of
assigner)Exception
public Collection<W> assignStateNamespace(RowData inputRow, long timestamp) throws Exception
InternalWindowProcessFunction
assignStateNamespace
in class InternalWindowProcessFunction<K,W extends Window>
inputRow
- the input elementtimestamp
- the timestamp of the element or the processing time (depends on the type of
assigner)Exception
public void prepareAggregateAccumulatorForEmit(W window) throws Exception
InternalWindowProcessFunction
prepareAggregateAccumulatorForEmit
in class InternalWindowProcessFunction<K,W extends Window>
window
- the windowException
public void cleanWindowIfNeeded(W window, long currentTime) throws Exception
InternalWindowProcessFunction
cleanWindowIfNeeded
in class InternalWindowProcessFunction<K,W extends Window>
window
- the window to cleanupcurrentTime
- the current timestampException
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.