oss_22_logger_enabled - #26
Conversation
|
🔒 Internal (dash0) — not for upstream.
|
|
📣 Public-facing draft — to be used for the upstream PR in Title: Add public What
WhyThe Logs API spec defines a SpecLogs API, "Logger's Enabled Operation". TestsNew API tests: no-op Backward compatibilityThe new processor hook is non-abstract with a |
|
This PR has been automatically marked as stale because it has not had any activity for 14 days. It will be closed if no further activity occurs within 14 days of this comment. |
Implements the Logs API "Enabled" operation. Adds a public enabled(context, severity_number, event_name) -> bool method to the API Logger (default False, matching the no-op logger) and to the SDK Logger, which delegates to processor-level enabled hooks and honors the logger configuration. Adds an optional enabled hook to LogRecordProcessor and the multi-processors so processors can report disabled cheaply.
fafd546 to
a215c15
Compare
Closes #22
Add public Logger.enabled(context, severity_number, event_name) to logs API and SDK, delegating to a processor-level enabled hook (Linear OSS-22, finding L3). Validation: api+sdk logs suites 129 passed, scope api+sdk+changelog.
Linear issue: https://linear.app/dash0/issue/OSS-22/l3-logs-apisdk-missing-the-loggerenabled-operation