Incubating: Add minimum severity and trace-based logger configuration#7529
Merged
jack-berg merged 7 commits intoopen-telemetry:mainfrom Nov 13, 2025
Conversation
This was referenced Aug 6, 2025
github-merge-queue bot
pushed a commit
to open-telemetry/opentelemetry-specification
that referenced
this pull request
Sep 23, 2025
…ers (#4612) Alternative to #4611 Some related prior discussions: - #4208 (comment) - #4207 (comment) Java POC @ open-telemetry/opentelemetry-java#7529 Declarative config for this is a bit nicer than in #4611, also supports applying different minimum severity levels to different loggers: ``` file_format: "1.0" logger_provider: logger_configurator/development: default_config: minimum_severity: WARN trace_based: true loggers: - name: "com.example.app.*" config: minimum_severity: INFO - name: "com.example.db.*" config: minimum_severity: ERROR ``` --------- Co-authored-by: Liudmila Molkova <neskazu@gmail.com> Co-authored-by: Robert Pająk <pellared@hotmail.com>
747bc91 to
f607dc9
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7529 +/- ##
============================================
+ Coverage 90.16% 90.21% +0.04%
- Complexity 7229 7247 +18
============================================
Files 821 822 +1
Lines 21809 21828 +19
Branches 2136 2139 +3
============================================
+ Hits 19665 19693 +28
+ Misses 1472 1469 -3
+ Partials 672 666 -6 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
d8f0544 to
c471c04
Compare
c471c04 to
6d538c3
Compare
trask
commented
Oct 22, 2025
sdk/logs/src/main/java/io/opentelemetry/sdk/logs/internal/LoggerConfig.java
Show resolved
Hide resolved
trask
commented
Oct 22, 2025
sdk/logs/src/main/java/io/opentelemetry/sdk/logs/SdkLogRecordBuilder.java
Show resolved
Hide resolved
ff37f15 to
7131c10
Compare
7131c10 to
a88392e
Compare
jack-berg
reviewed
Nov 6, 2025
sdk/logs/src/main/java/io/opentelemetry/sdk/logs/internal/LoggerConfig.java
Outdated
Show resolved
Hide resolved
sdk/logs/src/main/java/io/opentelemetry/sdk/logs/internal/LoggerConfig.java
Outdated
Show resolved
Hide resolved
sdk/logs/src/main/java/io/opentelemetry/sdk/logs/internal/LoggerConfig.java
Show resolved
Hide resolved
…d-trace-based-log-configuration
Member
Author
|
@jack-berg now that open-telemetry/opentelemetry-configuration#392 is merged, would you like me to add declarative config support in this PR or in a follow-up? |
Member
|
Followup is great. We need to wait for declarative config to cut a release anyway. No point in holding this up. |
jack-berg
approved these changes
Nov 13, 2025
|
@jack-berg @trask /open-telemetry/opentelemetry-configuration/pull/392 is released. When will declarative configuration be supported? |
Member
|
@mark-lu666 this was implemented and released in opentelemetry-java in v1.58.0! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Incubating implementation for open-telemetry/opentelemetry-specification#4612