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

Allow setting the exported service name using the JAEGER_SERVICE_NAME environment variable #1565

Closed
chgl opened this issue Oct 2, 2020 · 4 comments

Comments

@chgl
Copy link

chgl commented Oct 2, 2020

Is your feature request related to a problem? Please describe.

Quite a few options for the Jaeger exporter can already be configured using the JAEGER_ environment variables. However, the service name cannot.

Describe the solution you'd like

Allow setting the exported service name using the JAEGER_SERVICE_NAME environment variable.

Describe alternatives you've considered

Manually set the service name from the env vars:

const options = {
  serviceName: process.env.JAEGER_SERVICE_NAME  || 'my-service',
...
}

Additional context

To implement, a single line may be added to https://github.com/open-telemetry/opentelemetry-js/blob/master/packages/opentelemetry-exporter-jaeger/src/jaeger.ts#L53. I can give it a whirl :)

@vishaltak
Copy link

@chgl - Should the environment variables be OTEL_EXPORTER_JAEGER_* as mentioned in the OpenTelemetry specification here ?

Just trying to get information related to #1582

@chgl
Copy link
Author

chgl commented Oct 8, 2020

Interesting, thanks for pointing that out! I think ideally both JAEGER_AGENT_HOST and OTEL_EXPORTER_JAEGER_AGENT_HOST should be supported.

In this case though, there's no OTEL equivalent to the JAEGER_SERVICE_NAME, at least not yet: open-telemetry/opentelemetry-specification#709

@vishaltak
Copy link

I think ideally both JAEGER_AGENT_HOST and OTEL_EXPORTER_JAEGER_AGENT_HOST should be supported.

What should be the precedence between the two? Jaeger has announced deprecation of it's agent/collector in favour of OpenTelemetry.

In this case though, there's no OTEL equivalent to the JAEGER_SERVICE_NAME, at least not yet: open-telemetry/opentelemetry-specification#709

I could find OTEL_JAEGER_SERVICE_NAME in the Java SDK here. I'm don't think it is consistent across the SDKs.

Also, the parameters used to intialize the Exporter are different across languages. Example: agent host is specified as host in Javscript and as agent_host_name in Python.

@pichlermarc
Copy link
Member

Closing as not planned as @opentelemtry/exporter-jaeger is now deprecated and Jaeger now supports OTLP

@pichlermarc pichlermarc closed this as not planned Won't fix, can't repro, duplicate, stale Sep 29, 2023
pichlermarc pushed a commit to dynatrace-oss-contrib/opentelemetry-js that referenced this issue Dec 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants