Interface PeriodicGate
- All Known Implementing Classes:
LocalPeriodicGate,StoreBackedPeriodicGate
public interface PeriodicGate
Coordinates periodic background work across callers (and optionally across nodes) using a
minimum-gap throttle. A successful
tryClaim(java.lang.String, java.time.Duration) means the caller may proceed; a
false return means another caller recently claimed the slot or the gap has not
elapsed.-
Method Summary
-
Method Details
-
tryClaim
Attempts to claim the named periodic slot.- Parameters:
name- logical slot identifier (e.g."memory-flush:USER:alice"or"skill-curator")minGap- minimum elapsed time since the last successful claim- Returns:
trueif the caller won the claim and may proceed,falseotherwise
-