#[non_exhaustive]pub struct DownstreamMetrics {Show 16 fields
pub requests_accepted: Counter,
pub requests_accepted_tcp: Counter,
pub requests_accepted_h1: Counter,
pub requests_accepted_h2: Counter,
pub requests_accepted_h1_connect: Counter,
pub requests_accepted_h1_upgrade: Counter,
pub requests_accepted_h2_connect: Counter,
pub requests_accepted_h2_extended_connect: Counter,
pub requests_denied: Counter,
pub requests_completed: Counter,
pub requests_failed: Counter,
pub iroh_connections_opened: Counter,
pub iroh_connections_closed_idle: Counter,
pub iroh_connections_closed_error: Counter,
pub bytes_to_upstream: Counter,
pub bytes_from_upstream: Counter,
}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.requests_accepted: CounterTotal number of downstream requests that began processing (HTTP or TCP).
requests_accepted_tcp: CounterTCP-only requests (proxy is operating in ProxyMode::Tcp).
requests_accepted_h1: CounterHTTP/1 requests that reached the downstream proxy.
requests_accepted_h2: CounterHTTP/2 requests that reached the downstream proxy.
requests_accepted_h1_connect: CounterHTTP/1 CONNECT requests, i.e. e2e tunnels.
requests_accepted_h1_upgrade: CounterHTTP/1 upgrade requests (WebSocket, etc.) that were forwarded.
requests_accepted_h2_connect: CounterHTTP/2 CONNECT requests (excluding extended CONNECT), i.e. e2e tunnels.
requests_accepted_h2_extended_connect: CounterHTTP/2 extended CONNECT requests (RFC 8441), i.e. WebSocket over HTTP/2.
requests_denied: CounterRequests rejected by the RequestHandler before opening an upstream tunnel.
requests_completed: CounterRequests that successfully finished and were proxied upstream.
requests_failed: CounterRequests that failed after being accepted (upstream or network error).
iroh_connections_opened: CounterNumber of QUIC connections opened toward upstream iroh nodes.
iroh_connections_closed_idle: CounterConnections that closed cleanly from the local side (pool dropped conn after idle timeout)
iroh_connections_closed_error: CounterConnections that terminated with an error (timeouts, transport errors, resets).
bytes_to_upstream: CounterBytes written to the upstream proxy (downstream ➜ upstream).
bytes_from_upstream: CounterBytes read from the upstream proxy (upstream ➜ downstream).
Implementations§
Source§impl DownstreamMetrics
impl DownstreamMetrics
Sourcepub fn active_requests(&self) -> u64
pub fn active_requests(&self) -> u64
Returns the number of requests currently in flight.
Calculated as accepted - completed - failed using saturating arithmetic.
Sourcepub fn total_iroh_connections(&self) -> u64
pub fn total_iroh_connections(&self) -> u64
Returns the total number of opened QUIC connections.
Sourcepub fn active_iroh_connections(&self) -> u64
pub fn active_iroh_connections(&self) -> u64
Returns the estimated number of currently open QUIC connections.
Trait Implementations§
Source§impl Debug for DownstreamMetrics
impl Debug for DownstreamMetrics
Source§impl Default for DownstreamMetrics
impl Default for DownstreamMetrics
Source§impl Iterable for DownstreamMetrics
impl Iterable for DownstreamMetrics
Source§fn field_count(&self) -> usize
fn field_count(&self) -> usize
Auto Trait Implementations§
impl !Freeze for DownstreamMetrics
impl RefUnwindSafe for DownstreamMetrics
impl Send for DownstreamMetrics
impl Sync for DownstreamMetrics
impl Unpin for DownstreamMetrics
impl UnsafeUnpin for DownstreamMetrics
impl UnwindSafe for DownstreamMetrics
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> 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> IntoIterable for Twhere
T: Iterable,
impl<T> IntoIterable for Twhere
T: Iterable,
Source§fn as_iterable(&self) -> &dyn Iterable
fn as_iterable(&self) -> &dyn Iterable
self as dyn Iterable