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 X-Opaque-Id to root level application.log #51451

Open
D-shaw opened this issue Jan 24, 2020 · 2 comments
Open

Add X-Opaque-Id to root level application.log #51451

D-shaw opened this issue Jan 24, 2020 · 2 comments
Labels
:Core/Infra/Logging Log management and logging utilities help wanted adoptme Team:Core/Infra Meta label for core/infra team

Comments

@D-shaw
Copy link

D-shaw commented Jan 24, 2020

In #31521 X-Opaque-Id was added to access logs and slow logs. It would be very useful for investigation if whenever Elasticsearch throws an exception, X-Opaque-Id is appended to the exception log which locates at root level application.log.

@pgomulka pgomulka added the :Core/Infra/Logging Log management and logging utilities label Jan 29, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-infra (:Core/Infra/Logging)

@D-shaw D-shaw changed the title Add x-opaque-id to root level application.log Add X-Opaque-Id to root level application.log Jan 31, 2020
@rjernst rjernst added the Team:Core/Infra Meta label for core/infra team label May 4, 2020
@rjernst rjernst added the needs:triage Requires assignment of a team area label label Dec 3, 2020
@pgomulka pgomulka added team-discuss and removed needs:triage Requires assignment of a team area label labels Dec 10, 2020
@pgomulka
Copy link
Contributor

pgomulka commented Feb 3, 2021

we discussed this on a core-infra sync and we thought it would be a good feature.
However I am not sure if we could make it work easily.
We propagate X-Opaque-ID header directly from request onto the ThreadContext and from there it goes into a deprecation logger or search task context.

In order to have it available everywhere we would have to introduce an ExceptionLogger that would have access to ThreadContext. This would however mean we would have to find all usages of loggers which log an exception and use ExceptionLogger there.

@rjernst rjernst added the help wanted adoptme label Feb 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Core/Infra/Logging Log management and logging utilities help wanted adoptme Team:Core/Infra Meta label for core/infra team
Projects
None yet
Development

No branches or pull requests

4 participants