fn start_exitstat(
    logger: slog::Logger,
    debug: bool,
) -> (Arc<Mutex<procfs::PidMap>>, Receiver<Error>) {
    let mut exit_driver = bpf::exitstat::ExitstatDriver::new(logger, debug);
    let exit_buffer = exit_driver.get_buffer();
    let (bpf_err_send, bpf_err_recv) = channel();
    thread::spawn(move || {
        match exit_driver.drive() {
            Ok(_) => (),
            Err(e) => bpf_err_send.send(e).unwrap(),
        };
    });

    (exit_buffer, bpf_err_recv)
}
// Exitstat runs a bpf program that hooks into process exit events. This allows below to keep
// track of processes whose lifetimes are shorter than polling interval.
Exitstat runs a bpf program that hooks into process exit events. This allows below to keep
track of processes whose lifetimes are shorter than polling interval.
Exitstat runs a bpf program that hooks into process exit events . This allows below to keep track of processes whose lifetimes are shorter than polling interval .
fn start_exitstat(
    logger: slog::Logger,
    debug: bool,
) -> (Arc<Mutex<procfs::PidMap>>, Receiver<Error>) {
    let mut exit_driver = bpf::exitstat::ExitstatDriver::new(logger, debug);
    let exit_buffer = exit_driver.get_buffer();
    let (bpf_err_send, bpf_err_recv) = channel();
    thread::spawn(move || {
        match exit_driver.drive() {
            Ok(_) => (),
            Err(e) => bpf_err_send.send(e).unwrap(),
        };
    });
    (exit_buffer, bpf_err_recv)
}
fn start_exitstat ( logger : slog :: Logger , debug : bool , ) -> ( Arc < Mutex < procfs :: PidMap > > , Receiver < Error > ) { let mut exit_driver = bpf :: exitstat :: ExitstatDriver :: new ( logger , debug ) ; let exit_buffer = exit_driver . get_buffer ( ) ; let ( bpf_err_send , bpf_err_recv ) = channel ( ) ; thread :: spawn ( move | | { match exit_driver . drive ( ) { Ok ( _ ) => ( ) , Err ( e ) => bpf_err_send . send ( e ) . unwrap ( ) , } ; } ) ; ( exit_buffer , bpf_err_recv ) }
Exitstat runs a bpf program that hooks into process exit events.
Exitstat runs a bpf program that hooks into process exit events .
logger
slog::Logger
debug
bool
logger
slog::Logger
debug
bool