-
Notifications
You must be signed in to change notification settings - Fork 5k
Support absence of OTEL_* config variables injected in containers #2621
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
base: main
Are you sure you want to change the base?
Support absence of OTEL_* config variables injected in containers #2621
Conversation
| tracer = trace.get_tracer_provider().get_tracer("recommendation-server") | ||
| meter = metrics.get_meter_provider().get_meter("recommendation-server") |
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.
this parameter is the instrumentation scope nam, not the service name.
|
@puckpuck FYI a first step heading toward OTLP-protocol agnostic instrumentation. |
|
@cyrille-leclerc I don't understand the need of this PR. If the user forgets to set an env var, this will just mask the error. I'd rather have the service fail to start with a message saying |
|
Initially, I wanted this behaviour because the when combining the otel-kube-stack with the otel-demo components within the same chart, the demo components first starts without being injected the Then I did somecresearch and found that most apm agent don't fail the process when misconfigured which made a lot of sense to me and I came to the conclusion that the demo should exhibit the same behaviour: if monitoring config is missing, don't fail the service, just report the failure in a non blocking manner. Does it clarify?
My understanding is that OTel SDKs gracefully degrade if not provided configuration, like setting the export to the OTLP endpoint on |
I'd love to have more opinions on this. (@rogercoll, @puckpuck and @mviitane, wdyt?!) To me, the main goal of the OTel Demo is to demonstrate OTel. If a service starts successfully, but without OTel configured, then the service is not showcasing what was supposed to. |
|
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
|
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
Changes
Ensure the docker container can start in the absence of OTEL_* config variables injected in containers by Docker Compose or K8s.
Rationale:
OTEL_EXPORTER_OTLP_ENDPOINTis passed to themOTEL_*config through the Otel Operator if the container supports absence of those ev vars.Merge Requirements
For new features contributions, please make sure you have completed the following
essential items:
CHANGELOG.mdupdated to document new feature additionsMaintainers will not merge until the above have been completed. If you're unsure
which docs need to be changed ping the
@open-telemetry/demo-approvers.