logd: Logging as an Enabling Runtime Discipline
Most logging packages treat output as an afterthought—an unconstrained print() or a synchronous ANSI box wrapped around the active thread. But when you are engineering a system under real computational load with continuous calculations, high-throughput network streams, or 120Hz display budgets, an innocent string interpolation quietly steals microseconds, triggers garbage collection churn, and drops frames.
I built logd because I needed an instrument of control, not an obstacle. Inspired by the architectural maturity of Python's logging module and enterprise event routers, but rebuilt natively for Dart’s event-loop and isolate boundaries. It grew organically from an uncompromising rule: the observer must never alter the runtime determinism of the system being observed.
Never Drop a Frame
Formatting, ANSI layout, and file I/O offloaded to background worker isolates in ~15µs, safeguarding 8.3ms frame budgets.
Never Pay for Silence
Disabled subtrees short-circuit at O(1) with zero allocations. Version-based cache invalidation avoids costly tree walks on hot paths.
Never Crash the Host
Isolated InternalLogger and fallback sinks prevent infinite circular error loops when disks fill or sockets throw.
logd core engine·logd_toon AI token telemetry·logd_dio HTTP & cURL·logd_sqlite WAL sink·logd_network WebSockets·logd_html/md CI dossiers