I'm using the datastax Java cassandra driver (3.0.2) to connect to a cassandra cluster. In case of a NoHostAvailableException i want to retry after some seconds. Is is correct, that none of the predefined policies covers this requirement? I think i have to implement a custom Policy:
public class CustomRetryPolicy implements RetryPolicy {...}
- DefaultRetryPolicy
This implementation triggers a maximum of one retry, and only if enough replicas had responded to the read request but data was not retrieved amongst those.
- DowngradingConsistencyRetryPolicy
A retry policy that sometimes retries with a lower consistency level than the one initially requested.
- FallThroughRetryPolicy
A retry policy that never retries (nor ignores).
- LoggingRetryPolicy
A retry policy that wraps another policy, logging the decision made by its sub-policy