-
Notifications
You must be signed in to change notification settings - Fork 870
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
Remove support to override create key #1887
Conversation
Indeed this removes one of the testing case otelAsGrpc, but we should not expose an API just for this purpose until we know for sure we need it (applying the rule of minimal API). Also the createKey it is a strange method on the Storage (which should encapsulate only methods related to storage, and the creation of the key is a Context property). In the future if needed this should be a method on the Context or other ContextKeyFactory, not on the Storage. Signed-off-by: Bogdan Drutu <bogdandrutu@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The otelAsGrpc
case is the true interop case and most important. It's definitely going to be important as I start to add context interop in the instrumentation (took a week to update the SDK dependency in instrumentation due to several Java 8 bytecode issues but finally ready!).
The naming is definitely an issue, how about renaming ContextStorage
to something more generic, maybe ContextManager
, ContextProvider
?
Not sure, I think the
I think we need 2 classes |
But I think if instrumentation propagates the context, which it often does, changes will get out of sync We had a user report about it open-telemetry/opentelemetry-java-instrumentation#1313 (comment) So I'd like to continue to try with the key customization and removing the method would block that.
Yeah as long as it's one SPI, that sounds nice. |
I can send a PR for that bug without the key. Let me send it first to see that it is possible without key |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems this isn't needed, thanks!
Codecov Report
@@ Coverage Diff @@
## master #1887 +/- ##
=========================================
Coverage ? 85.14%
Complexity ? 1462
=========================================
Files ? 177
Lines ? 5774
Branches ? 592
=========================================
Hits ? 4916
Misses ? 652
Partials ? 206
Continue to review full report at Codecov.
|
Indeed this removes one of the testing case otelAsGrpc, but we should not expose an API just for this purpose until we know for sure we need it (applying the rule of minimal API).
Also the createKey it is a strange method on the Storage (which should encapsulate only methods related to storage, and the creation of the key is a Context property).
In the future if needed this should be a method on the Context or other ContextKeyFactory, not on the Storage.
Signed-off-by: Bogdan Drutu bogdandrutu@gmail.com