1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
//! Read-only observation surface used by the `ice-rpc-monitor` observer.
//!
//! Lets an external process attach to the channels an ice-rpc process exposes
//! without touching the hot path: only the zero-copy `RpcHeader` (sequence,
//! timestamp) and the payload length are read, never the rkyv payload. The
//! identity of the emitter (PID, node id, publisher id) is read from the
//! **native** iceoryx2 sample [`Emitter`], so the wire header carries none.
//!
//! The observer is linked against the **same service definitions** as the
//! providers and consumers, so it can also decode the payloads. Each `#[service]`
//! trait generates a `{Trait}Decoder` implementing [`ServiceDecoder`]; register
//! them in a [`Decoders`] registry, then the monitor renders every message with
//! the [`Display`](std::fmt::Display) implementation of the service types, or
//! with their [`Debug`](std::fmt::Debug) implementation when they have none
//! (see [`render_value!`]).
//!
//! # Two concerns, two modules
//!
//! - `inventory` answers *what is running*: the iceoryx2 nodes and their
//! liveness, the services and their role in a channel, and the file layout
//! iceoryx2 uses for its segments;
//! - `decode` answers *what was said*: the rendering of a payload and the
//! registry of the decoders.
//!
//! The split is what keeps a statistics-only observer free of the rendering
//! code: a monitor that never decodes does not carry the `Display` machinery.
pub use crate;
pub use ;
pub use ;
// Plumbing of the code generated with the `monitoring` feature: `render_value!`
// resolves these names through `ice_rpc::monitor`, so they stay reachable here.
pub use ;
pub use craterender_value;