Repository navigation
Setting management.observations.conventions to open-telemetry enables neither semantic convention - #52619
Merged
wilkinsona merged 1 commit intoNov 4, 2026
Conversation
wilkinsona
force-pushed
the
observation-conventions-dashed-value
branch
from
November 4, 2026 17:16
f71223e to
c959a8a
Compare
wilkinsona
pushed a commit
to b84330808/spring-boot
that referenced
this pull request
Nov 4, 2026
Compare the canonical form of the management.observations.conventions value with the canonical name of the conventions. Prior to this commit, only the exact enum name and the form without separators matched, so the documented 'open-telemetry' value matched neither MICROMETER nor OPEN_TELEMETRY. Signed-off-by: Wei-Lun Li <[email protected]> See spring-projectsgh-52619
Compare the canonical form of the management.observations.conventions value with the canonical name of the conventions. Prior to this commit, only the exact enum name and the form without separators matched, so the documented 'open-telemetry' value matched neither MICROMETER nor OPEN_TELEMETRY. Signed-off-by: Wei-Lun Li <[email protected]> See spring-projectsgh-52619
wilkinsona
force-pushed
the
observation-conventions-dashed-value
branch
from
November 4, 2026 17:16
c959a8a to
978afd5
Compare
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.
The reference docs say to set
management.observations.conventionstoopen-telemetryto switch to OpenTelemetry's semantic conventions.ObservationPropertiesbinds it fine, but@ConditionalOnSemanticConventionsdoesn't match it.SemanticConventions.isActiveonly accepts the enum name ignoring case (open_telemetry) or the form without separators (opentelemetry). As a result, withopen-telemetryneitherMICROMETERnorOPEN_TELEMETRYis active, and the WebMvc/WebFlux auto-configuration defines noServerRequestObservationConventionat all.This change compares the canonical form of the property value with the canonical name, the same way the lenient enum conversion does, so dashes are ignored too.
SemanticConventionsTests.ignoresDashMatchandConditionalOnSemanticConventionsTests.whenPropertyIsSetToDashedOpenTelemetryOnlyOpenTelemetryIsActivefail without the change and pass with it.