open-telemetry / open-telemetry/opentelemetry-java

Support selected runtime config changes

Open
#8,549 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Feature Request
Dominant language
Java
Stars
2.5k
Forks
1k
Avg merge
3d 17h
Merged PRs (30d)
58

Description

Is your feature request related to a problem? Please describe.
The contrib/dynamic-control project is adding capability to allow the SDK and agent to change some configurations at runtime. This is being done in a roundabout way, and should be supported more straightforwardly by the SDK

Describe the solution you'd like

  • if a policy changes that results in a new sampler config, call OpenTelemetrySdk.getSdkTracerProvider().setSampler(newSampler)
  • if a policy changes that results loggers being turned off or on, call OpenTelemetrySdk.getSdkLoggerProvider().setLoggerConfigurator(newLoggerConfigurator)
  • set Exporters at runtime?
  • change logging to debug at runtime?

Describe alternatives you've considered
This isn't necessary, the contrib/dynamic-control is already implementing the changes using indirect handling. However if this is to be an accepted part of the SDK, then the changes should be added to the SDK

Additional context
Discussion thread here. There is also https://github.com/open-telemetry/opentelemetry-java/pull/8076

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the OpenTelemetrySdk.getSdkTracerProvider() and getSdkLoggerProvider() entry points, then review contrib/dynamic-control and the referenced pull requests #2881 and #8076. Determine which runtime changes are intended to be supported—samplers, logger configurators, exporters, or log levels—and use the resulting API scope and tests as the completion criteria.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
observability
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.