Skip to main content

NativePhysicalWatchIdentity

Trait NativePhysicalWatchIdentity 

Source
pub unsafe trait NativePhysicalWatchIdentity {
    // Required methods
    fn retained_pidfd(&self) -> BorrowedFd<'_>;
    fn process_id(&self) -> i32;
    fn birth_identity(&self) -> u64;
    fn watch_is_healthy(&self) -> bool;
}
Expand description

Identity retained by the actual backend watch for this run’s root process.

§Safety

Implement only for a private owner constructed from a successful real watch registration. The pidfd and IDs must name that exact registration and remain immutable; watch_is_healthy must consult that retained watch’s actual state. A numeric PID, a parsed packet, or a socketpair creator is not this authority.

Required Methods§

Source

fn retained_pidfd(&self) -> BorrowedFd<'_>

The actual registered birth, retained by this owner.

Source

fn process_id(&self) -> i32

Actual guest-visible root process ID from that registration.

Source

fn birth_identity(&self) -> u64

Actual pidfs inode of that birth.

Source

fn watch_is_healthy(&self) -> bool

The retained watcher is still running without failure.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§