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

How to access in Plugin the Elastic Trace ID #20

Open
iqmeta opened this issue Jul 12, 2023 · 0 comments
Open

How to access in Plugin the Elastic Trace ID #20

iqmeta opened this issue Jul 12, 2023 · 0 comments
Labels
kind/question a question

Comments

@iqmeta
Copy link

iqmeta commented Jul 12, 2023

Hi,
we use https://doc.traefik.io/traefik/observability/tracing/elastic
Is it possible to log within plugin getting the trace id from request?

So we see in ContainerLog / APM etc. whatever happened in the plugin,
during the whole call cascade.

Header/Config/EnvVar?

event better something like this:

logger.Log(logging.Entry{
  Payload: "Did this",
  HttpRequest: &logging.HttpRequest{Request: r},
  //Traceparent : req.Header.Get("Traceparent") // or elastic-apm-traceparent
})

Cheers, Otto

@ldez ldez added the kind/question a question label Jul 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/question a question
Projects
None yet
Development

No branches or pull requests

2 participants