pub enum FailoverAction {
Retry(Duration),
RetryWith {
delay: Duration,
request: Box<ModelRequest>,
},
Next,
Stop,
}Expand description
What a Failover does after a failed attempt.
Variants§
Retry(Duration)
Try the same step again after this delay.
RetryWith
Try the same step again after delay with request instead (fewer
output tokens, no images, default options). Later attempts on the
step keep it; the next step starts from the original request.
Next
Move to the next step.
Stop
Give up: no other step would do better.
Trait Implementations§
Source§impl Clone for FailoverAction
impl Clone for FailoverAction
Source§fn clone(&self) -> FailoverAction
fn clone(&self) -> FailoverAction
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 FailoverAction
impl Debug for FailoverAction
Source§impl PartialEq for FailoverAction
impl PartialEq for FailoverAction
impl StructuralPartialEq for FailoverAction
Auto Trait Implementations§
impl Forget for FailoverAction
impl Freeze for FailoverAction
impl Move for FailoverAction
impl RefUnwindSafe for FailoverAction
impl Send for FailoverActionwhere
BoxRaw<ModelRequest>: Send,
impl Sync for FailoverActionwhere
BoxRaw<ModelRequest>: Sync,
impl Unpin for FailoverAction
impl UnsafeUnpin for FailoverAction
impl UnwindSafe for FailoverActionwhere
BoxRaw<ModelRequest>: UnwindSafe,
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> ⓘ
Converts
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> ⓘ
Converts
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