public class DetectNewPartitionsRangeTracker extends TimestampRangeTracker
TimestampRangeTracker
. It has a different logic for tryClaim method. It ignores claims for the
same timestamp multiple times.RestrictionTracker.HasProgress, RestrictionTracker.IsBounded, RestrictionTracker.Progress, RestrictionTracker.TruncateResult<RestrictionT>
lastAttemptedPosition, lastClaimedPosition, range
Constructor and Description |
---|
DetectNewPartitionsRangeTracker(TimestampRange range) |
Modifier and Type | Method and Description |
---|---|
boolean |
tryClaim(com.google.cloud.Timestamp position)
Attempts to claim the given position.
|
checkDone, currentRestriction, getProgress, isBounded, trySplit
public DetectNewPartitionsRangeTracker(TimestampRange range)
public boolean tryClaim(com.google.cloud.Timestamp position)
Must be equal or larger than the last successfully claimed position.
tryClaim
in class TimestampRangeTracker
true
if the position was successfully claimed, false
if it is outside
the current TimestampRange
of this tracker (in that case this operation is a
no-op).