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

Should the demo set exception message as span's status description #1412

Closed
cijothomas opened this issue Feb 26, 2024 · 2 comments
Closed

Should the demo set exception message as span's status description #1412

cijothomas opened this issue Feb 26, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@cijothomas
Copy link
Member

Bug Report

Which version of the demo you are using? : main branch

Symptom

https://github.com/open-telemetry/opentelemetry-demo/blob/main/src/cartservice/src/services/CartService.cs#L75 Is storing Exception message into status description. As per the SetStatus spec, the description should be documented and predictable. I am wondering if this is an intentional thing or a leftover from some previous state?

open-telemetry/opentelemetry-dotnet#5025 OTel .NET's instrumentation library removed setting exception message to status.description before its 1st stable release....

What is the expected behavior?

Not sure. This is more like a question - should we set exception message into status description.

@cijothomas cijothomas added the bug Something isn't working label Feb 26, 2024
@puckpuck
Copy link
Contributor

puckpuck commented Mar 1, 2024

I believe we are doing this properly. The specification says that Instrumentation Libraries should set this to be documented and predictable. Since this is not an instrumentation library, what we are doing would be the expected behavior to see the error message as returned to our code if an error occurs.

When the status is set to Error by Instrumentation Libraries, the Description SHOULD be documented and predictable.

@puckpuck
Copy link
Contributor

Closing this issue since we are setting this in the application code and not as part of an instrumentation library. Feel free to re-open if you feel otherwise and we can further discuss.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants