pub struct ConnectionInfo { /* private fields */ }Expand description
Immutable identity and transport facts for one installed connection.
Protocol records, request metadata, tracing, and lifecycle events retain the same value. It remains valid after logical close so the final physical-close observation names the same connection.
Implementations§
Source§impl ConnectionInfo
impl ConnectionInfo
Sourcepub fn id(&self) -> ConnectionId
pub fn id(&self) -> ConnectionId
Returns the pool-assigned physical connection identity.
Sourcepub fn owner_partition(&self) -> PartitionId
pub fn owner_partition(&self) -> PartitionId
Returns the partition that owns this connection’s I/O and driver.
Sourcepub fn protocol(&self) -> ConnectionProtocol
pub fn protocol(&self) -> ConnectionProtocol
Returns the established HTTP protocol.
Sourcepub fn local_addr(&self) -> Option<SocketAddr>
pub fn local_addr(&self) -> Option<SocketAddr>
Returns the connector-reported local socket address, when available.
Sourcepub fn remote_addr(&self) -> Option<SocketAddr>
pub fn remote_addr(&self) -> Option<SocketAddr>
Returns the connector-reported remote socket address, when available.
Sourcepub fn connect_path(&self) -> ConnectPath
pub fn connect_path(&self) -> ConnectPath
Returns how this connection reaches its origin.
Sourcepub fn is_proxied(&self) -> bool
pub fn is_proxied(&self) -> bool
Returns whether an HTTP proxy participates in this connection path.
Sourcepub fn establishment(&self) -> Option<&ConnectionEstablishmentMetadata>
pub fn establishment(&self) -> Option<&ConnectionEstablishmentMetadata>
Returns successful establishment measurements, when installation completed.
Trait Implementations§
Auto Trait Implementations§
impl !Freeze for ConnectionInfo
impl !RefUnwindSafe for ConnectionInfo
impl !UnwindSafe for ConnectionInfo
impl Send for ConnectionInfo
impl Sync for ConnectionInfo
impl Unpin for ConnectionInfo
impl UnsafeUnpin for ConnectionInfo
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> 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 moreCreates a shared type from an unshared type.