Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an SPI for customizing Config just before it's set #6010

Merged
merged 3 commits into from
May 16, 2022

Conversation

mateuszrzeszutek
Copy link
Member

@mateuszrzeszutek mateuszrzeszutek commented May 11, 2022

I thought this might be a useful thing to have, e.g. when you want to set a property based on the value of some another property. I added it to javaagent-tooling initially, but we can move to to extension-api if we decide to support that in public API.

@mateuszrzeszutek mateuszrzeszutek requested a review from a team as a code owner May 11, 2022 13:37
Copy link
Member

@trask trask left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you think it makes sense to combine ConfigCustomizer and ConfigPropertySource in some way?

@mateuszrzeszutek
Copy link
Member Author

Hmm, it probably would make sense -- we could add a Map<String, String> defaultProperties() (or Config defaultProperties()?) method to the customizer interface, and just deprecate the ConfigPropertySource.

@trask trask merged commit cb7421c into open-telemetry:main May 16, 2022
@mateuszrzeszutek mateuszrzeszutek deleted the config-customizer branch May 16, 2022 19:16
RashmiRam pushed a commit to RashmiRam/opentelemetry-auto-instr-java that referenced this pull request May 23, 2022
…y#6010)

* Add an SPI for customizing Config just before it's set

* deprecate ConfigPropertySource in favor of ConfigCustomizer

* errorprone
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants