Class EpochManager<OUT>
- java.lang.Object
-
- org.apache.flink.table.runtime.operators.join.lookup.keyordered.EpochManager<OUT>
-
public class EpochManager<OUT> extends Object
Epoch manager segments inputs into distinct epochs, marked by the arrival of non-records(e.g. watermark). Records are assigned to a unique epoch based on their arrival.
-
-
Constructor Summary
Constructors Constructor Description EpochManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()voidcompleteOneRecord(Epoch<OUT> epoch)Complete one record in the specific epoch.Epoch<OUT>getActiveEpoch()LinkedList<Epoch<OUT>>getOutputQueue()Optional<Epoch<OUT>>getProperEpoch(org.apache.flink.streaming.api.watermark.Watermark watermark)voidonNonRecord(org.apache.flink.streaming.api.watermark.Watermark watermark, Runnable action)Add a non-record to the current epoch, close current epoch and open a new epoch.Epoch<OUT>onRecord()Add a record to the current epoch and return the current open epoch.
-
-
-
Method Detail
-
onRecord
public Epoch<OUT> onRecord()
Add a record to the current epoch and return the current open epoch.- Returns:
- the current open epoch.
-
getProperEpoch
public Optional<Epoch<OUT>> getProperEpoch(org.apache.flink.streaming.api.watermark.Watermark watermark)
-
onNonRecord
public void onNonRecord(org.apache.flink.streaming.api.watermark.Watermark watermark, Runnable action)Add a non-record to the current epoch, close current epoch and open a new epoch.- Parameters:
watermark- the new watermark.
-
completeOneRecord
public void completeOneRecord(Epoch<OUT> epoch)
Complete one record in the specific epoch. Must be invoked within task thread.- Parameters:
epoch- the specific epoch
-
close
public void close()
-
getOutputQueue
@VisibleForTesting public LinkedList<Epoch<OUT>> getOutputQueue()
-
-