Some tracer libraries such as dd-trace (Datadog) have special logic when the error type is a Throwable, but are not able to do anything with a Cause.
Before I would see this with no details about the error:
After that change, I would get the error details with the full stack trace:
The spec says "For languages that support such a thing (e.g., Java, Python), the actual Throwable/Exception/Error object instance itself." so I think it makes sense not just for Datadog.
Some tracer libraries such as dd-trace (Datadog) have special logic when the error type is a
Throwable
, but are not able to do anything with aCause
.Before I would see this with no details about the error:
After that change, I would get the error details with the full stack trace:
The spec says "For languages that support such a thing (e.g., Java, Python), the actual Throwable/Exception/Error object instance itself." so I think it makes sense not just for Datadog.
Relevant logic in dd-trace: https://github.com/DataDog/dd-trace-java/blob/a760c687369c971fa38d95c103883ed672394e6c/dd-trace-ot/src/main/java/datadog/opentracing/DefaultLogHandler.java#L45