-
Notifications
You must be signed in to change notification settings - Fork 821
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
Logs emitted by LoggerProvider are missing the resource attributes #4645
Comments
They're simply not added to the output of the console exporter, right? |
From what I can see they're in the exported data but not logged via the console exporter. |
I see, my apologies for missing that. |
No worries, this was by design. Though I can see that it's confusing when it's not there. I've run into that multiple times when trying to troubleshoot apps running in k8s that I couldn't see the resources in the console exporter when I enabled it. For that reason I added logging the resource to the ConsoleSpanExporter (#4605 classified as a feature). I'll re-classify this issue as a feature. If you want you can open a PR to make the same change for the console log exporter. 🙂 |
|
What happened?
Steps to Reproduce
Run the setup code attached
Expected Result
A log record emitted with the resource attributes
Actual Result
A log record without the resource attributes, e.g.:
Additional Details
See code below.
This happens in both span context and where there's no active span recording.
OpenTelemetry Setup Code
package.json
Relevant log output
The text was updated successfully, but these errors were encountered: