Class WatermarkEstimators.MonotonicallyIncreasing

  • All Implemented Interfaces:
    TimestampObservingWatermarkEstimator<org.joda.time.Instant>, WatermarkEstimator<org.joda.time.Instant>
    Enclosing class:
    WatermarkEstimators

    public static class WatermarkEstimators.MonotonicallyIncreasing
    extends java.lang.Object
    implements TimestampObservingWatermarkEstimator<org.joda.time.Instant>
    A watermark estimator that observes timestamps of records output from a DoFn reporting the timestamp of the last element seen as the current watermark.

    Note that this watermark estimator expects output timestamps in monotonically increasing order. If they are not, then the watermark will advance based upon the last observed timestamp as long as it is greater then any previously reported watermark.

    • Constructor Summary

      Constructors 
      Constructor Description
      MonotonicallyIncreasing​(org.joda.time.Instant watermark)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.joda.time.Instant currentWatermark()
      Return estimated output watermark.
      org.joda.time.Instant getState()
      Get current state of the WatermarkEstimator instance, which can be used to recreate the WatermarkEstimator when processing the restriction.
      void observeTimestamp​(org.joda.time.Instant timestamp)
      Update watermark estimate with latest output timestamp.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MonotonicallyIncreasing

        public MonotonicallyIncreasing​(org.joda.time.Instant watermark)
    • Method Detail

      • currentWatermark

        public org.joda.time.Instant currentWatermark()
        Description copied from interface: WatermarkEstimator
        Return estimated output watermark. This method must return monotonically increasing watermarks across instances that are constructed from prior state.
        Specified by:
        currentWatermark in interface WatermarkEstimator<org.joda.time.Instant>