Skip to content

The ContextStorageProvider system prop and error message differ #7318

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

Open
LaurentTreguier opened this issue May 4, 2025 · 2 comments
Open
Labels
Bug Something isn't working

Comments

@LaurentTreguier
Copy link
Contributor

Inside of context/src/main/java/io/opentelemetry/context/LazyStorage.java, the io.opentelemetry.context.contextStorageProvider system property is checked for providers.
However, in the IllegalStateExceptions thrown further down in the class, error messages mention the io.opentelemetry.context.ContextStorageProvider property instead (with an uppercase "C" for ContextStorageProvider).

I'm a little bit out of my depth here regarding system property naming, so I'm not sure which one is correct and which one is a typo though

@LaurentTreguier LaurentTreguier added the Bug Something isn't working label May 4, 2025
@jkwatson
Copy link
Contributor

jkwatson commented May 8, 2025

I don't think we can really change the system property at this point, so we should consider the message to be wrong. Can you contribute a small PR to fix it? Thanks!

@LaurentTreguier
Copy link
Contributor Author

Fix proposed in #7342

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants