You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The HotRod can fail if we try to run it in Kubernetes with Jaeger Agent (with a Service name jaeger-agent) or with one of the old parameters like JAEGER_AGENT_PORT (that have OTEL_EXPORTER_* alternatives).
During a short investigation, I found the issue added after PR #5437.
After removing expvar the method
I'm using the HotRod with the ENV OTEL_EXPORTER_OTLP_ENDPOINT. By mistake, I deployed the deprecated Jaeger Agent (as a DaemonSet) with a Kubernetes Service jaeger-agent name. So Kubernetes injected the ENV JAEGER_AGENT_PORT inside the HotRod pod and the HotRod started crashing with the error.
Jaeger backend version
v1.58.x
SDK
No response
Pipeline
No response
Stogage backend
Cassandra
Operating system
Linux
Deployment model
Kubernetes, binaries
Deployment configs
No response
The text was updated successfully, but these errors were encountered:
…gertracing#5760)
## Which problem is this PR solving?
- Resolvesjaegertracing#5759
## Description of the changes
- Invoke mapping function (which takes logger) after the logger is
initialized
- It is safe to do because none of the env vars control the logic for
logger initialization
## How was this change tested?
- `$ JAEGER_AGENT_PORT=xyz go run ./examples/hotrod all`
- Before the change this command would cause a panic
Signed-off-by: Yuri Shkuro <[email protected]>
What happened?
The HotRod can fail if we try to run it in Kubernetes with Jaeger Agent (with a Service name
jaeger-agent
) or with one of the old parameters likeJAEGER_AGENT_PORT
(that haveOTEL_EXPORTER_*
alternatives).During a short investigation, I found the issue added after PR #5437.
After removing
expvar
the methodhere https://github.com/jaegertracing/jaeger/blob/main/examples/hotrod/cmd/root.go#L59
now calling with a non-initialized
logger
variable.As a result, the logger in
jaegerclientenv2otel.MapJaegerToOtelEnvVars
will failhttps://github.com/jaegertracing/jaeger/blob/main/internal/jaegerclientenv2otel/envvars.go#L57
with nil pointer.
Steps to reproduce
JAEGER_AGENT_HOST=<value>
orJAEGER_AGENT_PORT=<value>
(in Kubernetes deployment or for local run)Expected behavior
It should run as usual, without exceptions, and print in logs
Relevant log output
Screenshot
No response
Additional context
I'm using the HotRod with the ENV
OTEL_EXPORTER_OTLP_ENDPOINT
. By mistake, I deployed the deprecated Jaeger Agent (as a DaemonSet) with a Kubernetes Servicejaeger-agent
name. So Kubernetes injected the ENVJAEGER_AGENT_PORT
inside the HotRod pod and the HotRod started crashing with the error.Jaeger backend version
v1.58.x
SDK
No response
Pipeline
No response
Stogage backend
Cassandra
Operating system
Linux
Deployment model
Kubernetes, binaries
Deployment configs
No response
The text was updated successfully, but these errors were encountered: