Enum ProxyErrorType
#[non_exhaustive]pub enum ProxyErrorType {
Show 33 variants
DnsTimeout,
DnsError,
DestinationNotFound,
DestinationUnavailable,
DestinationIpProhibited,
DestinationIpUnroutable,
ConnectionRefused,
ConnectionTerminated,
ConnectionTimeout,
ConnectionReadTimeout,
ConnectionWriteTimeout,
ConnectionLimitReached,
TlsProtocolError,
TlsCertificateError,
TlsAlertReceived,
HttpRequestError,
HttpRequestDenied,
HttpResponseIncomplete,
HttpResponseHeaderSectionSize,
HttpResponseHeaderSize,
HttpResponseBodySize,
HttpResponseTrailerSectionSize,
HttpResponseTrailerSize,
HttpResponseTransferCoding,
HttpResponseContentCoding,
HttpResponseTimeout,
HttpUpgradeFailed,
HttpProtocolError,
ProxyInternalResponse,
ProxyInternalError,
ProxyConfigurationError,
ProxyLoopDetected,
Other(Box<str>),
}http and std only.Expand description
A proxy error type (RFC 9209 §2.3).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
DnsTimeout
dns_timeout: timeout resolving the next hop.
DnsError
dns_error: DNS error resolving the next hop (see rcode, info-code).
DestinationNotFound
destination_not_found: no next hop could be determined.
destination_unavailable: the next hop is considered unavailable.
DestinationIpProhibited
destination_ip_prohibited: the next hop’s address may not be used.
DestinationIpUnroutable
destination_ip_unroutable: the next hop’s address cannot be reached.
ConnectionRefused
connection_refused: the next hop refused the connection.
ConnectionTerminated
connection_terminated: the next hop closed the connection.
ConnectionTimeout
connection_timeout: connecting to the next hop timed out.
ConnectionReadTimeout
connection_read_timeout: reading from the next hop timed out.
ConnectionWriteTimeout
connection_write_timeout: writing to the next hop timed out.
ConnectionLimitReached
connection_limit_reached: the intermediary’s connection limit was reached.
TlsProtocolError
tls_protocol_error: a TLS protocol error with the next hop.
TlsCertificateError
tls_certificate_error: the next hop’s certificate was rejected.
TlsAlertReceived
tls_alert_received: the next hop sent a TLS alert.
HttpRequestError
http_request_error: the request is invalid; answer with the applicable 4xx.
HttpRequestDenied
http_request_denied: the request was denied by policy.
HttpResponseIncomplete
http_response_incomplete: the next hop’s response was incomplete.
HttpResponseHeaderSectionSize
http_response_header_section_size: the response header section was too large.
HttpResponseHeaderSize
http_response_header_size: a response header field line was too large.
HttpResponseBodySize
http_response_body_size: the response body was too large.
HttpResponseTrailerSectionSize
http_response_trailer_section_size: the response trailer section was too large.
HttpResponseTrailerSize
http_response_trailer_size: a response trailer field line was too large.
HttpResponseTransferCoding
http_response_transfer_coding: a transfer-coding error in the response.
HttpResponseContentCoding
http_response_content_coding: a content-coding error in the response.
HttpResponseTimeout
http_response_timeout: the next hop’s response timed out.
HttpUpgradeFailed
http_upgrade_failed: the protocol upgrade failed.
HttpProtocolError
http_protocol_error: an HTTP protocol error with the next hop.
ProxyInternalResponse
proxy_internal_response: the intermediary generated the response itself.
ProxyInternalError
proxy_internal_error: an internal error in the intermediary.
ProxyConfigurationError
proxy_configuration_error: the intermediary is misconfigured.
ProxyLoopDetected
proxy_loop_detected: the request looped through the intermediary.
Other(Box<str>)
An error type registered after RFC 9209 (a valid Token).
Implementations§
§impl ProxyErrorType
impl ProxyErrorType
pub fn recommended_status(&self) -> Option<StatusCode>
pub fn recommended_status(&self) -> Option<StatusCode>
The status RFC 9209 recommends answering with, if any.
Trait Implementations§
§impl Clone for ProxyErrorType
impl Clone for ProxyErrorType
§fn clone(&self) -> ProxyErrorType
fn clone(&self) -> ProxyErrorType
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more§impl Debug for ProxyErrorType
impl Debug for ProxyErrorType
impl Eq for ProxyErrorType
§impl Hash for ProxyErrorType
impl Hash for ProxyErrorType
§impl PartialEq for ProxyErrorType
impl PartialEq for ProxyErrorType
impl StructuralPartialEq for ProxyErrorType
Auto Trait Implementations§
impl Freeze for ProxyErrorType
impl RefUnwindSafe for ProxyErrorType
impl Send for ProxyErrorType
impl Sync for ProxyErrorType
impl Unpin for ProxyErrorType
impl UnsafeUnpin for ProxyErrorType
impl UnwindSafe for ProxyErrorType
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§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§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a rama_grpc::Request§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§fn and<P, B, E>(self, other: P) -> And<T, P>
fn and<P, B, E>(self, other: P) -> And<T, P>
Policy that returns Action::Follow only if self and other return
Action::Follow. Read more