-
Notifications
You must be signed in to change notification settings - Fork 8.8k
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
Move required OpenTelemetry packages to prometheus/prometheus #13842
Comments
@jesusvazquez WDYT of this problem? You have more history on OTLP in Prometheus than I do. In particular, I'd like to understand if there are talks about moving the storage/remote/otlptranslator/ directory contents into Prometheus and out of opentelemetry-collector-contrib (so the latter depends on the former). |
I don't have opinion on moving packages, I recall one discussion if owners of OTel contrib would like to "donate" this lib to us and how maintainership would work for it etc. I am sure @gouthamve and @dashpole know more. In the mean time, since we don't expect people to import or use this library we vendor in Otel collector or SDKs, why not removing code that uses any global variables in our |
I'll bring this topic to today's prometheus - otel workgroup to see if we can expedite owning the lib now that its been months of updating it, having the endpoint live in our release etc Knowing that this is causing issues to some users is even more reason to pursue it and then we'll be more in control to make the changes we need. |
Original thread: https://cloud-native.slack.com/archives/C01LSCJBXDZ/p1689161965395529 Discussion from the prom-wg yesterday: https://docs.google.com/document/d/19bnXziPn2MZ9wO6684UoI4D-LCjGL5bTJkGhux29bx8/edit#bookmark=id.399s77tz4cjr |
Reading back through, the primary concerns with the move were:
The dependency tree for both translator packages currently contains these collector dependencies:
Semconv is used for AttributeServiceName, AttributeServiceInstanceID, and AttributeServiceNamespace constants. Those could be copied, or we could use constants from opentelemetry-go. coreinternal is used for test data generation, and could be copied. Given other dependencies are stable, I think it eliminates (1) as a concern. For Stability guarantees, we had discussed these as potential parts of the agreement:
|
Notes from today's WG meeting:
|
👋
I brought this topic up with the team and the above two things are the main ones that make me think it's best to have different code bases.
Although this means divergence we're still very involved in the Prometheus - Opentelemetry calls and if we make any meaningful improvements over time we'll bring them up 💪 cc @dashpole Sometime soon @aknuds1 and I plan to work on a PR to make this a reality and finally close this issue. |
Here is the first improvement to PRW translation :) |
Relates to #13842 After a lot of productive discussion between the Prometheus and OpenTelemetry community we decided that it made sense for Prometheus to own its own copy of the code in charge for handling OTLP ingestion traffic. This commit is removing the README and update-copy.sh files that had the previous steps to update the code. Also it is updating the licensing of all the files to make sure the OpenTelemetry provenance is explicit and to state the new ownership. Signed-off-by: Jesus Vazquez <jesusvzpg@gmail.com> Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
@dashpole @Aneurysm9 I'm trying to diverge code while respecting the licensing in this PR #13991 Please have a look mostly at the file header where the relicensing is happening. |
Relates to #13842 After a lot of productive discussion between the Prometheus and OpenTelemetry community we decided that it made sense for Prometheus to own its own copy of the code in charge for handling OTLP ingestion traffic. This commit is removing the README and update-copy.sh files that had the previous steps to update the code. Also it is updating the licensing of all the files to make sure the OpenTelemetry provenance is explicit and to state the new ownership. Signed-off-by: Jesus Vazquez <jesusvzpg@gmail.com> Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
This is now completed and this issue can be closed. Thanks everyone for the help 💪 |
Problem
Currently, Prometheus has a copy/paste code of two OpenTelemetry translators. The rationale for this is described in README.md in the otlptranslator package:
This becomes a blocker for projects that depend on both
open-telemetry/opentelemetry-collector-contrib
andprometheus/prometheus
, because the code contains registrations of feature gates against a global registry (example), which will panic on duplicate registrations. The symptom would be a panic like this:Proposed solution
As mentioned in the README.md in the otlptranslator package:
To address the problem, Prometheus should become the new home for required packages and OpenTelemetry should import them instead from their Prometheus dependency.
The text was updated successfully, but these errors were encountered: