Skip to content

Commit 6e2e8ae

Browse files
committed
RetryPolicy: Doc comments for RetryDecision
1 parent 6217b70 commit 6e2e8ae

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

scylla/src/policies/retry/retry_policy.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,17 @@ pub struct RequestInfo<'a> {
1717
pub consistency: Consistency,
1818
}
1919

20+
/// Returned by implementations of RetryPolicy. Instructs the driver on what
21+
/// to do about the request after it failed.
2022
#[derive(Clone, Debug, PartialEq, Eq)]
2123
pub enum RetryDecision {
24+
/// Request will be sent to the same shard on the same host.
2225
RetrySameTarget(Option<Consistency>), // None means that the same consistency should be used as before
26+
/// Request will be sent to the next target generated by load balancing policy.
2327
RetryNextTarget(Option<Consistency>), // ditto
28+
/// Fails the whole request.
2429
DontRetry,
30+
/// Will cause the driver to return an empty successful response.
2531
IgnoreWriteError,
2632
}
2733

0 commit comments

Comments
 (0)