Class DetectNewPartitionsRangeTracker
java.lang.Object
org.apache.beam.sdk.transforms.splittabledofn.RestrictionTracker<TimestampRange,com.google.cloud.Timestamp>
 
org.apache.beam.sdk.io.gcp.spanner.changestreams.restriction.TimestampRangeTracker
org.apache.beam.sdk.io.gcp.spanner.changestreams.restriction.DetectNewPartitionsRangeTracker
- All Implemented Interfaces:
 RestrictionTracker.HasProgress
This restriction tracker delegates most of its behavior to an internal 
TimestampRangeTracker. It has a different logic for tryClaim method. It ignores claims for the
 same timestamp multiple times.- 
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.beam.sdk.transforms.splittabledofn.RestrictionTracker
RestrictionTracker.HasProgress, RestrictionTracker.IsBounded, RestrictionTracker.Progress, RestrictionTracker.TruncateResult<RestrictionT> - 
Field Summary
Fields inherited from class org.apache.beam.sdk.io.gcp.spanner.changestreams.restriction.TimestampRangeTracker
lastAttemptedPosition, lastClaimedPosition, range, timeSupplier - 
Constructor Summary
Constructors - 
Method Summary
Modifier and TypeMethodDescriptionbooleantryClaim(com.google.cloud.Timestamp position) Attempts to claim the given position.Methods inherited from class org.apache.beam.sdk.io.gcp.spanner.changestreams.restriction.TimestampRangeTracker
checkDone, currentRestriction, getProgress, isBounded, setTimeSupplier, tryClaim, trySplit 
- 
Constructor Details
- 
DetectNewPartitionsRangeTracker
 
 - 
 - 
Method Details
- 
tryClaim
public boolean tryClaim(com.google.cloud.Timestamp position) Attempts to claim the given position.Must be equal or larger than the last successfully claimed position.
- Overrides:
 tryClaimin classTimestampRangeTracker- Returns:
 trueif the position was successfully claimed,falseif it is outside the currentTimestampRangeof this tracker (in that case this operation is a no-op).
 
 -