pub struct ClientPeer {
pub src: String,
pub process: String,
pub pid: u32,
pub since: Instant,
pub responsible_app: Option<String>,
pub current_rx_bps: u64,
pub current_tx_bps: u64,
pub bytes_rcvd: Option<u64>,
pub bytes_sent: Option<u64>,
pub last_sample_at: Option<Instant>,
}Expand description
One peer observed by the lsof poller as connected to a forwarded port.
Fields§
§src: String§process: String§pid: u32Owner pid of the client socket. Surfaced in the CLIENTS card so users can correlate a connection with a local process.
since: Instant§responsible_app: Option<String>On macOS, the user-facing app that “owns” this socket according
to the kernel-tracked responsible-pid. Lets the CLIENTS card show
Safari for a WebKit.Networking XPC daemon, or Ghostty for
a psql started from a Ghostty terminal. None when responsible
pid resolution is unavailable, equals self, or the lookup failed.
current_rx_bps: u64Most-recent rx/tx bytes-per-second sample, derived by diffing per-socket cumulative byte counters between lsof polls. Zero until a second sample arrives. macOS uses a per-pid fallback when per-socket counters are not available.
current_tx_bps: u64§bytes_rcvd: Option<u64>Cumulative byte counters at the most recent sample. Used to diff
against the next sample. None until the first sample arrives.
bytes_sent: Option<u64>§last_sample_at: Option<Instant>Time of the most recent sample. None until the first sample.
Trait Implementations§
Source§impl Clone for ClientPeer
impl Clone for ClientPeer
Source§fn clone(&self) -> ClientPeer
fn clone(&self) -> ClientPeer
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for ClientPeer
impl RefUnwindSafe for ClientPeer
impl Send for ClientPeer
impl Sync for ClientPeer
impl Unpin for ClientPeer
impl UnsafeUnpin for ClientPeer
impl UnwindSafe for ClientPeer
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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