public class BatchTimerInternals extends Object implements TimerInternals
TimerInternals.TimerData| Constructor and Description |
|---|
BatchTimerInternals(org.joda.time.Instant processingTime) |
| Modifier and Type | Method and Description |
|---|---|
void |
advanceProcessingTime(ReduceFnRunner<?,?,?,?> runner,
org.joda.time.Instant newProcessingTime) |
void |
advanceWatermark(ReduceFnRunner<?,?,?,?> runner,
org.joda.time.Instant newWatermark) |
org.joda.time.Instant |
currentProcessingTime()
Returns the current timestamp in the
TimeDomain.PROCESSING_TIME time domain. |
org.joda.time.Instant |
currentWatermarkTime()
Returns an estimate of the current timestamp in the
TimeDomain.EVENT_TIME time domain. |
void |
deleteTimer(TimerInternals.TimerData timer)
Deletes the given timer.
|
void |
setTimer(TimerInternals.TimerData timer)
Writes out a timer to be fired when the watermark reaches the given
timestamp.
|
String |
toString() |
public BatchTimerInternals(org.joda.time.Instant processingTime)
public void setTimer(TimerInternals.TimerData timer)
TimerInternals The combination of namespace, timestamp and domain uniquely
identify a timer. Multiple timers set for the same parameters can be safely deduplicated.
setTimer in interface TimerInternalspublic void deleteTimer(TimerInternals.TimerData timer)
TimerInternalsdeleteTimer in interface TimerInternalspublic org.joda.time.Instant currentProcessingTime()
TimerInternalsTimeDomain.PROCESSING_TIME time domain.currentProcessingTime in interface TimerInternalspublic org.joda.time.Instant currentWatermarkTime()
TimerInternalsTimeDomain.EVENT_TIME time domain.currentWatermarkTime in interface TimerInternalspublic void advanceWatermark(ReduceFnRunner<?,?,?,?> runner, org.joda.time.Instant newWatermark)
public void advanceProcessingTime(ReduceFnRunner<?,?,?,?> runner, org.joda.time.Instant newProcessingTime)