-
Notifications
You must be signed in to change notification settings - Fork 275
Open
Description
Motivation: Automotive Use Case
- Contextual / Hierarchical Logging
- Current target (module path) is too flat for complex automotive applications where multiple layers/modules may reuse common subsystems.
- Developers need to distinguish who logged what not only by module but also by parent/ancestor context.
- Add optional hierarchical context (e.g. ECU → Subsystem → Component).
- Such context could be attached automatically (per logger instance) and optionally extended by the user.
- Enables better traceability of log origins in safety-critical systems.
- Type-Aware Logging
- Today everything is stringified, discarding type info needed by automotive backends (e.g. DLT expects type fidelity: numeric vs string vs struct).
- Proposal: allow passing typed values directly (info!(42), info!("user_id" = 43), info!(User { id: 7 })).
- Preserves fidelity for DLT and similar tools, enables filtering/sorting, while staying backward-compatible and simple for developers.
- Fatal Log Level
- Current Error conflates recoverable and unrecoverable failures.
- Add a Fatal level for logging critical, fail-stop conditions.
- Essential for automotive where safety hazards must be identified and escalated distinctly.
Benefits
- Improves interoperability with standards (e.g. DLT, AUTOSAR logging).
- Strengthens suitability for safety-critical domains (ISO 26262 compliance).
- Still lightweight: could be added as opt-in features, maintaining compatibility.
Metadata
Metadata
Assignees
Labels
No labels