Struct aws_sdk_appmesh::types::GrpcRetryPolicy
source · #[non_exhaustive]pub struct GrpcRetryPolicy {
pub per_retry_timeout: Option<Duration>,
pub max_retries: i64,
pub http_retry_events: Option<Vec<String>>,
pub tcp_retry_events: Option<Vec<TcpRetryPolicyEvent>>,
pub grpc_retry_events: Option<Vec<GrpcRetryPolicyEvent>>,
}Expand description
An object that represents a retry policy. Specify at least one value for at least one of the types of RetryEvents, a value for maxRetries, and a value for perRetryTimeout. Both server-error and gateway-error under httpRetryEvents include the Envoy reset policy. For more information on the reset policy, see the Envoy documentation.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.per_retry_timeout: Option<Duration>The timeout for each retry attempt.
max_retries: i64The maximum number of retry attempts.
http_retry_events: Option<Vec<String>>Specify at least one of the following values.
-
server-error – HTTP status codes 500, 501, 502, 503, 504, 505, 506, 507, 508, 510, and 511
-
gateway-error – HTTP status codes 502, 503, and 504
-
client-error – HTTP status code 409
-
stream-error – Retry on refused stream
tcp_retry_events: Option<Vec<TcpRetryPolicyEvent>>Specify a valid value. The event occurs before any processing of a request has started and is encountered when the upstream is temporarily or permanently unavailable.
grpc_retry_events: Option<Vec<GrpcRetryPolicyEvent>>Specify at least one of the valid values.
Implementations§
source§impl GrpcRetryPolicy
impl GrpcRetryPolicy
sourcepub fn per_retry_timeout(&self) -> Option<&Duration>
pub fn per_retry_timeout(&self) -> Option<&Duration>
The timeout for each retry attempt.
sourcepub fn max_retries(&self) -> i64
pub fn max_retries(&self) -> i64
The maximum number of retry attempts.
sourcepub fn http_retry_events(&self) -> &[String]
pub fn http_retry_events(&self) -> &[String]
Specify at least one of the following values.
-
server-error – HTTP status codes 500, 501, 502, 503, 504, 505, 506, 507, 508, 510, and 511
-
gateway-error – HTTP status codes 502, 503, and 504
-
client-error – HTTP status code 409
-
stream-error – Retry on refused stream
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .http_retry_events.is_none().
sourcepub fn tcp_retry_events(&self) -> &[TcpRetryPolicyEvent]
pub fn tcp_retry_events(&self) -> &[TcpRetryPolicyEvent]
Specify a valid value. The event occurs before any processing of a request has started and is encountered when the upstream is temporarily or permanently unavailable.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .tcp_retry_events.is_none().
sourcepub fn grpc_retry_events(&self) -> &[GrpcRetryPolicyEvent]
pub fn grpc_retry_events(&self) -> &[GrpcRetryPolicyEvent]
Specify at least one of the valid values.
If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use .grpc_retry_events.is_none().
source§impl GrpcRetryPolicy
impl GrpcRetryPolicy
sourcepub fn builder() -> GrpcRetryPolicyBuilder
pub fn builder() -> GrpcRetryPolicyBuilder
Creates a new builder-style object to manufacture GrpcRetryPolicy.
Trait Implementations§
source§impl Clone for GrpcRetryPolicy
impl Clone for GrpcRetryPolicy
source§fn clone(&self) -> GrpcRetryPolicy
fn clone(&self) -> GrpcRetryPolicy
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for GrpcRetryPolicy
impl Debug for GrpcRetryPolicy
source§impl PartialEq for GrpcRetryPolicy
impl PartialEq for GrpcRetryPolicy
impl StructuralPartialEq for GrpcRetryPolicy
Auto Trait Implementations§
impl Freeze for GrpcRetryPolicy
impl RefUnwindSafe for GrpcRetryPolicy
impl Send for GrpcRetryPolicy
impl Sync for GrpcRetryPolicy
impl Unpin for GrpcRetryPolicy
impl UnwindSafe for GrpcRetryPolicy
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit)source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more