#[non_exhaustive]pub struct HttpFaultInjection {
pub abort: Option<HttpFaultAbort>,
pub delay: Option<HttpFaultDelay>,
/* private fields */
}Available on crate features
region-url-maps or url-maps only.Expand description
The specification for fault injection introduced into traffic to test the resiliency of clients to backend service failure. As part of fault injection, when clients send requests to a backend service, delays can be introduced by the load balancer on a percentage of requests before sending those request to the backend service. Similarly requests from clients can be aborted by the load balancer for a percentage of requests.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.abort: Option<HttpFaultAbort>The specification for how client requests are aborted as part of fault injection.
delay: Option<HttpFaultDelay>The specification for how client requests are delayed as part of fault injection, before being sent to a backend service.
Implementations§
Source§impl HttpFaultInjection
impl HttpFaultInjection
pub fn new() -> Self
Sourcepub fn set_abort<T>(self, v: T) -> Selfwhere
T: Into<HttpFaultAbort>,
pub fn set_abort<T>(self, v: T) -> Selfwhere
T: Into<HttpFaultAbort>,
Sourcepub fn set_or_clear_abort<T>(self, v: Option<T>) -> Selfwhere
T: Into<HttpFaultAbort>,
pub fn set_or_clear_abort<T>(self, v: Option<T>) -> Selfwhere
T: Into<HttpFaultAbort>,
Sourcepub fn set_delay<T>(self, v: T) -> Selfwhere
T: Into<HttpFaultDelay>,
pub fn set_delay<T>(self, v: T) -> Selfwhere
T: Into<HttpFaultDelay>,
Sourcepub fn set_or_clear_delay<T>(self, v: Option<T>) -> Selfwhere
T: Into<HttpFaultDelay>,
pub fn set_or_clear_delay<T>(self, v: Option<T>) -> Selfwhere
T: Into<HttpFaultDelay>,
Trait Implementations§
Source§impl Clone for HttpFaultInjection
impl Clone for HttpFaultInjection
Source§fn clone(&self) -> HttpFaultInjection
fn clone(&self) -> HttpFaultInjection
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HttpFaultInjection
impl Debug for HttpFaultInjection
Source§impl Default for HttpFaultInjection
impl Default for HttpFaultInjection
Source§fn default() -> HttpFaultInjection
fn default() -> HttpFaultInjection
Returns the “default value” for a type. Read more
Source§impl Message for HttpFaultInjection
impl Message for HttpFaultInjection
Source§impl PartialEq for HttpFaultInjection
impl PartialEq for HttpFaultInjection
impl StructuralPartialEq for HttpFaultInjection
Auto Trait Implementations§
impl Freeze for HttpFaultInjection
impl RefUnwindSafe for HttpFaultInjection
impl Send for HttpFaultInjection
impl Sync for HttpFaultInjection
impl Unpin for HttpFaultInjection
impl UnwindSafe for HttpFaultInjection
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
Mutably borrows from an owned value. Read more