Struct Diagnostics
Generated from cargo doc --no-deps -p nemo-relay-builtins -p nemo-relay-diagnostics -p nemo-relay-logging -p nemo-relay-plugin-host -p nemo-relay-codecs -p nemo-relay -p nemo-relay-runtime -p nemo-relay-model-pricing -p nemo-relay-resource-metrics -p nemo-relay-observability -p nemo-relay-adaptive -p nemo-relay-pii-redaction -p nemo-relay-ffi -p nemo-relay-types -p nemo-relay-plugin -p nemo-relay-worker-proto -p nemo-relay-worker.
Independent diagnostics context with immutable startup enablement.
Clones share this context only. State and budgets are independent of logger lifetime and of any other explicitly isolated embedded contexts.
Implementations
impl Diagnostics
Referenced types: Diagnostics
from_settings
Referenced types: SourceIdentity, DiagnosticsSettings, Result, Diagnostics, DiagnosticError
Construct a context using the startup owner’s selected mode and capacities.
Enabled mode validates arithmetic and admits backend storage before use. The circular-history allocation uses the global allocation-error handler on allocation failure; fallible pool reservations return an error. Disabled mode retains lightweight source/settings state without registry, history, detail, query, or projection pools. Source role/version metadata is capped at 128 UTF-8 bytes; the supplied UUID is preserved.
selected_process_default
Referenced types: Option, Diagnostics
Inspect a selected context without consuming an uninitialized default.
install_process_default
Referenced types: SourceIdentity, DiagnosticsSettings, Result, Diagnostics, DiagnosticError
Install before handing out default handles. Once used, inert handles are never silently upgraded to a different startup mode.
process_default
Referenced types: Diagnostics
Return the installed process context or initialize a disabled default.
Install enabled settings before the first lookup. Early disabled handles are never implicitly upgraded by logger or plugin construction.
limits
Referenced types: DiagnosticLimits
Configured capacities, independently of current occupancy or disablement.
source
Referenced types: SourceIdentity
Source incarnation shared by every observation from this context.
reader
Referenced types: DiagnosticsReader
Issue a read capability without materializing or allocating a query page.
snapshot
Referenced types: DiagnosticQuery, Result, SnapshotLease, DiagnosticError
Capture a bounded page through this context’s reader.
The lease holds a query permit until dropped. Reads never reset counters or pin history; configured disablement is returned explicitly. The query is borrowed only during capture and can be reused after this call.
register_component
Referenced types: ComponentRegistration, Result, ComponentRecorder, DiagnosticError
Reserve a component vocabulary and return its producer lease.
Admission cannot displace active summaries. The final recorder drop closes the component. Use Self::register_owned_component for explicit close and refresh authority. Disabled mode returns an inert recorder.
register_owned_component
Referenced types: ComponentRegistration, Result, ComponentOwner, ComponentRecorder, DiagnosticError
Reserve a component and separately issue owner and producer capabilities.
The owner can close or rotate this registration. Disabled mode issues inert handles without an active identity or backend reservation. Admission failures are explicit and recorded in reserved loss accounting.
subscribe_projection
Referenced types: Fn, DiagnosticOutputSummary, Send, Sync, Result, ProjectionGuard, DiagnosticError
Attach a bounded subscriber to approved operational summaries. Restricted retained evidence is never supplied to projection callbacks.
Callbacks run outside the store lock, may run concurrently, and have isolated panics. Disabled mode retains no callback and returns an inert guard. Arbitrary callback captures and retained copies remain caller-owned.
subscribe_fallible_projection
Referenced types: Fn, DiagnosticOutputSummary, Result, (), ProjectionError, Send, Sync, ProjectionGuard, DiagnosticError
Attach a subscriber that reports bounded conversion or delivery failure.
Errors update projection-loss accounting without undoing numeric acceptance. Separate publication workspaces cannot pin history. Disabled mode retains no callback and returns an inert guard.
memory_usage
Referenced types: DiagnosticMemoryUsage
Inspect reserved backend bytes and occupancy without changing evidence.
Inspection scans admitted slots and detail-block metadata without allocating. Disabled contexts report zero backend capacity. Lightweight facade state, caller-owned copies, thread stacks, and independent outputs are excluded.
Trait Implementations
impl Clone for Diagnostics
Referenced types: Clone, Diagnostics
clone
Referenced types: clone, Diagnostics
clone_from
Referenced types: clone_from
impl Debug for Diagnostics
Referenced types: Debug, Diagnostics
fmt
Referenced types: fmt, Formatter, Result, (), Error
impl Default for Diagnostics
Referenced types: Default, Diagnostics
default
Referenced types: default, Diagnostics