-
Notifications
You must be signed in to change notification settings - Fork 11
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
Add otel log data source for internal errors #886
Conversation
d655ad7
to
c74d8cc
Compare
33313c5
to
d4e6744
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #886 +/- ##
==========================================
- Coverage 81.00% 80.86% -0.15%
==========================================
Files 440 441 +1
Lines 11745 11752 +7
Branches 1795 1794 -1
==========================================
- Hits 9514 9503 -11
- Misses 1440 1456 +16
- Partials 791 793 +2
|
c74d8cc
to
8e44fc3
Compare
d4e6744
to
5f5f8e8
Compare
@@ -57,6 +57,8 @@ internal sealed class EmbType(type: String, subtype: String?) : TelemetryType { | |||
|
|||
internal object Exception : System("exception") | |||
|
|||
internal object InternalError : System("internal") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not a name that indicates that it's some sort of error or warning?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is what was suggested with Pablo/Austin
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess these don't have to something bad. But there's a pedanticness rising in me that says this should be a noun.........
I'll suck it up lol
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Question about why it's only called sys.internal
and doesn't indicate that there's some sort of unexpected error, but that's not blocking
alterSessionSpan(NoInputValidation) { | ||
this.addLog(throwable, true) { | ||
val schemaType = SchemaType.InternalError(throwable) | ||
LogEventData(schemaType, Severity.ERROR, "") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be make these logs private so they are not exported to the generic exporter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought that supplying true
to addLog
was enough to do that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh sweet you're right!
7a32051
to
1c4518b
Compare
1c4518b
to
6ee1288
Compare
Goal
Implements our internal telemetry using OTel logs. This is not hooked up to data capture yet - that will be done in a separate PR.
Testing
Added unit tests.