RUMM-2289 Add tracing sampling attribute#1092
Conversation
50896a3 to
8b5a9c9
Compare
ncreated
left a comment
There was a problem hiding this comment.
Looks good for the sampling logic 👍.
Codecov Report
@@ Coverage Diff @@
## develop #1092 +/- ##
===========================================
+ Coverage 83.23% 83.26% +0.03%
===========================================
Files 273 273
Lines 9344 9348 +4
Branches 1502 1503 +1
===========================================
+ Hits 7777 7783 +6
Misses 1148 1148
+ Partials 419 417 -2
|
| "pattern": "^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$" | ||
| }, | ||
| { | ||
| "type": "array", |
There was a problem hiding this comment.
are we using this event ? I don't remember to have something like this yet in the SDK.
There was a problem hiding this comment.
This schema is shared for all action children (i.e. Resources, Errors and Long Tasks). we used to only have an action.id: String, but now it can be either a String, or an array of Strings (for Frustration Signals)
| sourceType = event.sourceType.toSchemaSourceType() | ||
| ), | ||
| action = context.actionId?.let { ErrorEvent.Action(it) }, | ||
| action = context.actionId?.let { ErrorEvent.Action(listOf(it)) }, |
There was a problem hiding this comment.
why are we doing this ? Is there any situation where a LongTask will be caused by multiple actions ? Same question for all the other scopes.
There was a problem hiding this comment.
This can happen with frustration signals. The schema makes it so that an action.id can be either a string, or a list of string. Because we can't have such a thing in Kotlin, we go for the list of string which allows us to report both a single or multiple ids
0xnm
left a comment
There was a problem hiding this comment.
lgtm! I added one question regarding unexpected symbol.
| val opt = if (nullable) "?" else "" | ||
| beginControlFlow( | ||
| "$assignee = $getter$opt.asJsonArray$opt.let { %L ->", | ||
| "$assignee = $getter$opt.asJsonArray$opt.let·{·%L·->", |
There was a problem hiding this comment.
why there is a change with middle dot instead of space here and in ClassGenerator?
There was a problem hiding this comment.
This is part of KotlinPoet internals to mark non-breaking space. This ensures that the KotlinPoet file writer won't break a line on any of those space.
This is because some classNames get very large and the line breaking happens at an arbitrary size without knowledge of the syntax, leading to code that don't compile
What does this PR do?
Add the
_dd.rule_psrattribute for RUM Resources to let customer know the sampling rate in APM