-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
original stack trace for JsonEncoder #808
base: master
Are you sure you want to change the base?
Conversation
cc6b77c
to
9471624
Compare
Thanks @zeitlinger .
I didn't see in your code the json fields for https://opentelemetry.io/docs/specs/semconv/attributes-registry/exception/ |
I had in mind that the "raw stack trace" could reuse the Something like: CURRENT ...
"throwable": {
"className": "java.lang.RuntimeException",
"message": "Fraud detected",
"stepArray": [
{
"className": "com.mycompany.antifraud.FraudDetectionController",
"methodName": "checkOrder",
"fileName": "FraudDetectionController.java",
"lineNumber": 121
},
...
{
"className": "java.lang.Thread",
"methodName": "run",
"fileName": "Thread.java",
"lineNumber": 1583
}
]
} SUGGESTION ...
"throwable": {
"className": "java.lang.RuntimeException",
"message": "Fraud detected",
"stackTrace": "java.lang.RuntimeException: Fraud Detection Processing Exception\\n at com.mycompany.antifraud.FraudDetectionController.checkOrder(FraudDetectionController.java:117)\\n at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)\\n ...\\n at java.base/java.lang.Thread.run(Thread.java:1583)"
} |
c9aec45
to
0c74c0b
Compare
logback-classic/src/main/java/ch/qos/logback/classic/encoder/JsonEncoder.java
Outdated
Show resolved
Hide resolved
logback-classic/src/main/java/ch/qos/logback/classic/encoder/JsonEncoder.java
Outdated
Show resolved
Hide resolved
logback-classic/src/main/java/ch/qos/logback/classic/encoder/JsonEncoder.java
Outdated
Show resolved
Hide resolved
13ad536
to
bfe33c6
Compare
@cyrille-leclerc please check again |
It looks perfect to me, the config param |
@ceki I'm wondering if I found a bug here: logback/logback-classic/src/main/java/ch/qos/logback/classic/encoder/JsonEncoder.java Line 199 in bfe33c6
If |
…o logging backends Signed-off-by: Gregor Zeitlinger <gregor.zeitlinger@grafana.com>
bfe33c6
to
7473be1
Compare
@ceki can you review the PR? |
1 similar comment
@ceki can you review the PR? |
add option to encode Throwable in a raw format for easy ingestion into logging backends
Existing throwable encoding (
withThrowable
, enabled by default)new
withPlainStackTrace
format: