pub enum RetrySource {
RetryAfterMs,
RetryAfterSeconds,
RetryAfterDate,
OpenAiResetRequests,
OpenAiResetTokens,
AnthropicResetRequests,
AnthropicResetTokens,
AnthropicResetInputTokens,
AnthropicResetOutputTokens,
}Expand description
Where a retry delay came from. This is useful for logs and debugging.
Variants§
RetryAfterMs
Non-standard retry-after-ms header, in milliseconds.
RetryAfterSeconds
Standard retry-after header, in (possibly fractional) seconds.
RetryAfterDate
Standard retry-after header, as an HTTP-date.
OpenAiResetRequests
OpenAI x-ratelimit-reset-requests, in Go duration format.
OpenAiResetTokens
OpenAI x-ratelimit-reset-tokens, in Go duration format.
AnthropicResetRequests
Anthropic anthropic-ratelimit-requests-reset, as an RFC 3339 date.
AnthropicResetTokens
Anthropic anthropic-ratelimit-tokens-reset, as an RFC 3339 date.
AnthropicResetInputTokens
Anthropic anthropic-ratelimit-input-tokens-reset, as an RFC 3339 date.
AnthropicResetOutputTokens
Anthropic anthropic-ratelimit-output-tokens-reset, as an RFC 3339 date.
Trait Implementations§
Source§impl Clone for RetrySource
impl Clone for RetrySource
impl Copy for RetrySource
Source§impl Debug for RetrySource
impl Debug for RetrySource
impl Eq for RetrySource
Source§impl PartialEq for RetrySource
impl PartialEq for RetrySource
impl StructuralPartialEq for RetrySource
Auto Trait Implementations§
impl Freeze for RetrySource
impl RefUnwindSafe for RetrySource
impl Send for RetrySource
impl Sync for RetrySource
impl Unpin for RetrySource
impl UnsafeUnpin for RetrySource
impl UnwindSafe for RetrySource
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.