Replace declarative config bridge usages in contrib#2988
Draft
zeitlinger wants to merge 5 commits into
Draft
Conversation
Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
github-actions
Bot
requested review from
JonasKunz,
LikeTheSalad,
SylvainJuge and
jackshirazi
July 13, 2026 13:00
Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
zeitlinger
force-pushed
the
agent/replace-declarative-config-properties-bridge-usages
branch
from
July 13, 2026 15:07
09e9e74 to
7958c72
Compare
zeitlinger
force-pushed
the
agent/replace-declarative-config-properties-bridge-usages
branch
from
July 13, 2026 15:23
7958c72 to
3b81d9c
Compare
Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
zeitlinger
force-pushed
the
agent/replace-declarative-config-properties-bridge-usages
branch
from
July 13, 2026 15:46
3b81d9c to
e3fefc2
Compare
Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
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.
Blocked by open-telemetry/opentelemetry-java-instrumentation#19220
Summary
DeclarativeConfigPropertiesBridgeBuilderusages inspan-stacktraceandinferred-spansConfigPropertiesBackedConfigProvideraccess-path APIinferred-spanson flat underscore keysDeclarativeConfigPropertiesDurationUtil.parseDuration(...)Why
DeclarativeConfigPropertiesBridgeis being deprecated inopentelemetry-java-instrumentation, and these remaining contrib usages need to move off it first.This change depends on open-telemetry/opentelemetry-java-instrumentation#19220, which supersedes #15835 and adds the bridge helpers used here.
Related deprecation PR: open-telemetry/opentelemetry-java-instrumentation#19202
The unrelated
SamplingProfilerTestflake fix was split into #3000.How this uses the new bridge APIs
inferred-spansbridges the component root directly tootel.inferred.spans.withConfigPropertiesBackedConfigProvider.builder().setAccessPath("", "otel.inferred.spans.")span-stacktracebridges the component root directly tootel.java.experimental.span-stacktrace.the same wayDeclarativeConfigPropertiesDurationUtil.parseDuration(...)instead of carrying their own parsing copyBreaking behavior change
Declarative config YAML now only accepts integer millisecond values for these duration properties.
Examples:
min_duration: 100min_duration: 100msThat matches the behavior documented on
DeclarativeConfigPropertiesDurationUtil: flatConfigPropertiesinputs can still use string durations such as42ms, but non-ConfigPropertiesdeclarative config only accepts integer milliseconds.Testing
GRADLE_USER_HOME=/tmp/gradle-home-otel-java-contrib ./gradlew --no-build-cache --no-configuration-cache -PuseLocalMaven :span-stacktrace:check :inferred-spans:check