Interface SpeculativeRetryPolicy
-
- All Known Implementing Classes:
AlwaysSpeculativeRetryPolicy
,FixedSpeculativeRetryPolicy
,HybridSpeculativeRetryPolicy
,NeverSpeculativeRetryPolicy
,PercentileSpeculativeRetryPolicy
public interface SpeculativeRetryPolicy
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
SpeculativeRetryPolicy.Kind
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description long
calculateThreshold(SnapshottingTimer latency, long existingValue)
Calculate the delay in microseconds after which speculation takes placestatic SpeculativeRetryPolicy
fromString(java.lang.String str)
SpeculativeRetryPolicy.Kind
kind()
-
-
-
Method Detail
-
calculateThreshold
long calculateThreshold(SnapshottingTimer latency, long existingValue)
Calculate the delay in microseconds after which speculation takes place- Parameters:
latency
- snapshot of coordinator latencies (in microseconds)existingValue
- existing speculation threshold (in microseconds)- Returns:
- speculation delay (in microseconds).
-
kind
SpeculativeRetryPolicy.Kind kind()
-
fromString
static SpeculativeRetryPolicy fromString(java.lang.String str)
-
-