-
Notifications
You must be signed in to change notification settings - Fork 534
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
Unified pattern for instrumentation dependencies #986
Comments
If we state compatibility with API 1.0.0 we should test it somewhere. Not sure if using
It will most likely work correct but typescript will likely complain - see #983 Long term this could be fixed by replacing all classes in exported APIs by interfaces but I doubt this will happen soon. Not sure if this is even possible because I think we even export abstract classes at a few places. Also duplication of API can be problematic. If an instrumentation has a copy of API 1.1.0 in it's subtree and app uses 1.0.x the instrumentation won't create traces because the global installed |
We can configure
I think this also depends on the exact combination of usages. Instrumentation mostly depends on the API and
We talked about it a few weeks ago at the SIG, and understood this is unaviodable. |
Even if the same version is in both folders it wont work. And I think this has a good reason. Even if the class has the same source and therefore the same functionality an |
This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days. |
This issue was closed because it has been stale for 14 days with no activity. |
This issue is about dependencies in instrumentation
package.json
s, discussed hereThe current code base includes many instrumentations that have different dependencies patterns on
@opentelemetry/*
packages.I would like to get to a consensus about the correct way to do it, and then apply the decision on all pacakges
Peer dependency on
@opentelemetry/api
Should be set to minimum version that satisfies the instrumentation, with a caret. This will usually be:
This change is covered in #984 by @Flarna
Dev depenency on
@opentelemetry/api
Currently, each instrumentation uses a different version (probably the latest one available when it was created).
This dependency is used for build and test.
I guess we want to keep it pinned to enforce consistency, but the question is if it should be pinned to least supported version (
1.0.0
), or latest version (1.1.0
and bump on new releases).A suggestion is to use
test-all-versions
to verify tests are passing with various api versions, but we will still need a single version in package.json dependencies for all other tasks.Dependencies on
@opentelemetry/*
packagesShould instrumentation state the minimum supported version (e.g.
^1.0.0
), or the latest version (^1.2.0
). I guess both are OK, even if user is using old SDK version, instrumentation will just pull it's own copy version into another branch innode_modules
and will function correctly.Currently, there is inconsistency in these dependencies which I support in straightening and documenting the "right" template.
@Flarna - you always have good insights on these topics. What do you recommend doing?
The text was updated successfully, but these errors were encountered: