-
Notifications
You must be signed in to change notification settings - Fork 233
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
Span's add_event and record_exception not working with X-Ray #666
Comments
Hi @Kharvi-Code - unfortunately X-Ray does not have a concept of events like Jaeger. It would be a cool feature but there isn't any plan for it yet - events get dropped during conversion to X-Ray. Exceptions should be supported though so it's surprising to not have anything show. Are you able to share the JSON for the trace which can be downloaded from X-Ray? Also if you haven't, it would be good to run |
@anuraaga I have pulled the latest aws-collector and tried again. Still no exception recorded.
|
Thanks @Kharvi-Code - indeed the exception is not being exported to X-Ray. I realize it's because you don't call @willarmiros Do you know if the backend would generally expect exceptions to be exported even for successful spans? |
Thanks @anuraaga - Since I was using Jaeger before this where I was not setting status for failed spans, I was not aware that I have to explicitly set status for failed spans. |
@anuraaga I'm not sure if it's a requirement of the X-Ray backend to have a non-OK span for an exception to be recorded, but I do know that with the X-Ray SDKs calling Glad to see it worked as expected for now though. |
Closing issue as there is no further discussion on this. Thanks for the help. |
Span's add_event() and record_exception() are not working when exporter is X-Ray. For other exporters like Jaeger I could see Logs as a separate field in UI for add_event() and record_exception(). Looks like set_attribute() works fine as I can see the attributes in Metadata section of the span X-Ray.
Steps to reproduce:
Note: I have to use tracer.start_span instead of tracer.start_as_current_span as per the requirement
Expected:
s1.add_event("Tracing.........Foo...........", {}) - has to send logs/event to X-Ray (foo Segment)
s2.record_exception(e) - has to send Exception trace to X-Ray (bar Subsegment)
Actual:
Dont know where the events/logs will be for foo Segment in X-Ray.
Did not get Exception trace in Exception tab of bar Subsegment
The text was updated successfully, but these errors were encountered: