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 Go Auto-instrumentation application #1718

Open
rogercoll opened this issue Sep 16, 2024 · 2 comments
Open

Add Go Auto-instrumentation application #1718

rogercoll opened this issue Sep 16, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@rogercoll
Copy link
Contributor

Feature Request

Add a new Go service (or migrate a current one) that can be auto-instrumented with Go: https://github.com/open-telemetry/opentelemetry-go-instrumentation.
The Dockerfiles can reuse the image provided by the Operator: https://github.com/open-telemetry/opentelemetry-go-instrumentation/pkgs/container/opentelemetry-go-instrumentation%2Fautoinstrumentation-go

Is your feature request related to a problem?

No available example for Go auto-instrumentation.

Describe the solution you'd like:

The Go auto-instrumentation is based on eBPF, meaning that it will only work in Linux environments. The service could be marked as optional and only deploy it on these environments. Note that only a few libraries are compatible with the auto-instrumentation tool:

Any idea for the example app?

@rogercoll rogercoll added the enhancement New feature or request label Sep 16, 2024
@julianocosta89
Copy link
Member

I don't like the idea of having a service that just works in one specific environment.

We could maybe have a separate file with this:
https://github.com/open-telemetry/opentelemetry-demo/blob/main/src/productcatalogservice/main.go#L83-L130

Add an if to the main function and pass the OS via build-arg, env var or something like that. Than we do the decision to add the manual file, or to add the auto-instrumentation.

WDYT?

Does that make sense? Do you think this is doable?

@rogercoll
Copy link
Contributor Author

That seems it should work. My main concern will be regarding the docker-compose and Helm Charts, the Go auto instrumentation works as a sidecar container, meaning that we will need to modify the deployment files depending on the environment. And I agree with you, I would rather prefer to have a unified deployment experience than having different configurations depending on the environment.

There is an ongoing idea about moving this sidecar container to a collector's receiver, which I think it would simply our deployment files open-telemetry/opentelemetry-go-instrumentation#1026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants