pub struct SetPeerIdentity {
pub pid: Option<i32>,
pub uid: Option<i32>,
pub machine_id_hint: Option<String>,
pub machine_name: Option<String>,
}
Expand description
Client (relay service) -> Host. This is generated by the relay service to fill the producer identity in the guest. This message is sent to the host service before any IPCFrame is from a local producer is relayed. This is accepted only on AF_VSOCK and AF_INET sockets, where we cannot validate the endpoont of the connection. for AF_UNIX sockets, this is ignored and traced uses instead the SO_PEERCRED.
Fields§
§pid: Option<i32>
The UID and PID of the producer process.
uid: Option<i32>
§machine_id_hint: Option<String>
The hint for the tracing service to infer the machine ID. This field should satisfy the requriement that different machines should have different values. In practice, this filed contains the Linux kernel boot_id, or a hash of kernel bootup timestamp and uname(2) if boot_id isn’t available.
machine_name: Option<String>
Human-readable name associated to the producer’s machine. Provides the tracing service a new dimension to filter data sources on. Given the perfetto machine name is provided by users, there is no expectation of uniqueness across machines in a tracing session.
Implementations§
Source§impl SetPeerIdentity
impl SetPeerIdentity
Sourcepub fn machine_id_hint(&self) -> &str
pub fn machine_id_hint(&self) -> &str
Returns the value of machine_id_hint
, or the default value if machine_id_hint
is unset.
Sourcepub fn machine_name(&self) -> &str
pub fn machine_name(&self) -> &str
Returns the value of machine_name
, or the default value if machine_name
is unset.
Trait Implementations§
Source§impl Clone for SetPeerIdentity
impl Clone for SetPeerIdentity
Source§fn clone(&self) -> SetPeerIdentity
fn clone(&self) -> SetPeerIdentity
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for SetPeerIdentity
impl Debug for SetPeerIdentity
Source§impl Default for SetPeerIdentity
impl Default for SetPeerIdentity
Source§impl Message for SetPeerIdentity
impl Message for SetPeerIdentity
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
.