-
Notifications
You must be signed in to change notification settings - Fork 312
Refactor RUM telemetry #9526
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
Refactor RUM telemetry #9526
Conversation
🎯 Code Coverage 🔗 Commit SHA: d5dc373 | Docs | Was this helpful? Give us feedback! |
BenchmarksStartupParameters
See matching parameters
SummaryFound 1 performance improvements and 0 performance regressions! Performance is the same for 49 metrics, 9 unstable metrics.
Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.063 s) : 0, 1063127
Total [baseline] (8.635 s) : 0, 8634819
Agent [candidate] (1.06 s) : 0, 1059841
Total [candidate] (8.603 s) : 0, 8603242
section iast
Agent [baseline] (1.196 s) : 0, 1196249
Total [baseline] (9.299 s) : 0, 9299310
Agent [candidate] (1.184 s) : 0, 1183868
Total [candidate] (9.289 s) : 0, 9289354
gantt
title insecure-bank - break down per module: candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.457 ms) : 0, 1457
crashtracking [candidate] (1.45 ms) : 0, 1450
BytebuddyAgent [baseline] (733.682 ms) : 0, 733682
BytebuddyAgent [candidate] (731.828 ms) : 0, 731828
GlobalTracer [baseline] (252.696 ms) : 0, 252696
GlobalTracer [candidate] (251.786 ms) : 0, 251786
AppSec [baseline] (30.77 ms) : 0, 30770
AppSec [candidate] (30.565 ms) : 0, 30565
Debugger [baseline] (6.425 ms) : 0, 6425
Debugger [candidate] (6.331 ms) : 0, 6331
Remote Config [baseline] (699.195 µs) : 0, 699
Remote Config [candidate] (676.303 µs) : 0, 676
Telemetry [baseline] (16.387 ms) : 0, 16387
Telemetry [candidate] (16.268 ms) : 0, 16268
section iast
crashtracking [baseline] (1.455 ms) : 0, 1455
crashtracking [candidate] (1.445 ms) : 0, 1445
BytebuddyAgent [baseline] (856.967 ms) : 0, 856967
BytebuddyAgent [candidate] (847.422 ms) : 0, 847422
GlobalTracer [baseline] (248.103 ms) : 0, 248103
GlobalTracer [candidate] (243.488 ms) : 0, 243488
IAST [baseline] (28.199 ms) : 0, 28199
IAST [candidate] (28.772 ms) : 0, 28772
AppSec [baseline] (25.644 ms) : 0, 25644
AppSec [candidate] (26.967 ms) : 0, 26967
Debugger [baseline] (6.064 ms) : 0, 6064
Debugger [candidate] (6.08 ms) : 0, 6080
Remote Config [baseline] (594.531 µs) : 0, 595
Remote Config [candidate] (610.714 µs) : 0, 611
Telemetry [baseline] (8.206 ms) : 0, 8206
Telemetry [candidate] (8.26 ms) : 0, 8260
Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.061 s) : 0, 1061347
Total [baseline] (10.719 s) : 0, 10718870
Agent [candidate] (1.068 s) : 0, 1067531
Total [candidate] (10.734 s) : 0, 10733549
section appsec
Agent [baseline] (1.243 s) : 0, 1242556
Total [baseline] (11.165 s) : 0, 11165091
Agent [candidate] (1.236 s) : 0, 1236405
Total [candidate] (11.044 s) : 0, 11043810
section iast
Agent [baseline] (1.204 s) : 0, 1204244
Total [baseline] (11.114 s) : 0, 11113621
Agent [candidate] (1.2 s) : 0, 1200044
Total [candidate] (10.972 s) : 0, 10972244
section profiling
Agent [baseline] (1.216 s) : 0, 1216282
Total [baseline] (11.045 s) : 0, 11044767
Agent [candidate] (1.207 s) : 0, 1206998
Total [candidate] (10.878 s) : 0, 10877704
gantt
title petclinic - break down per module: candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section tracing
crashtracking [baseline] (1.445 ms) : 0, 1445
crashtracking [candidate] (1.461 ms) : 0, 1461
BytebuddyAgent [baseline] (732.233 ms) : 0, 732233
BytebuddyAgent [candidate] (737.455 ms) : 0, 737455
GlobalTracer [baseline] (252.502 ms) : 0, 252502
GlobalTracer [candidate] (253.209 ms) : 0, 253209
AppSec [baseline] (30.594 ms) : 0, 30594
AppSec [candidate] (30.723 ms) : 0, 30723
Debugger [baseline] (6.397 ms) : 0, 6397
Debugger [candidate] (6.412 ms) : 0, 6412
Remote Config [baseline] (688.034 µs) : 0, 688
Remote Config [candidate] (698.456 µs) : 0, 698
Telemetry [baseline] (16.524 ms) : 0, 16524
Telemetry [candidate] (16.382 ms) : 0, 16382
section appsec
crashtracking [baseline] (1.467 ms) : 0, 1467
crashtracking [candidate] (1.457 ms) : 0, 1457
BytebuddyAgent [baseline] (761.141 ms) : 0, 761141
BytebuddyAgent [candidate] (757.394 ms) : 0, 757394
GlobalTracer [baseline] (246.816 ms) : 0, 246816
GlobalTracer [candidate] (246.073 ms) : 0, 246073
IAST [baseline] (24.081 ms) : 0, 24081
IAST [candidate] (23.802 ms) : 0, 23802
AppSec [baseline] (170.12 ms) : 0, 170120
AppSec [candidate] (171.468 ms) : 0, 171468
Debugger [baseline] (6.099 ms) : 0, 6099
Debugger [candidate] (5.977 ms) : 0, 5977
Remote Config [baseline] (640.48 µs) : 0, 640
Remote Config [candidate] (614.387 µs) : 0, 614
Telemetry [baseline] (10.878 ms) : 0, 10878
Telemetry [candidate] (8.357 ms) : 0, 8357
section iast
crashtracking [baseline] (1.47 ms) : 0, 1470
crashtracking [candidate] (1.461 ms) : 0, 1461
BytebuddyAgent [baseline] (863.693 ms) : 0, 863693
BytebuddyAgent [candidate] (860.041 ms) : 0, 860041
GlobalTracer [baseline] (245.625 ms) : 0, 245625
GlobalTracer [candidate] (247.017 ms) : 0, 247017
IAST [baseline] (29.085 ms) : 0, 29085
IAST [candidate] (28.885 ms) : 0, 28885
AppSec [baseline] (28.102 ms) : 0, 28102
AppSec [candidate] (26.497 ms) : 0, 26497
Debugger [baseline] (6.094 ms) : 0, 6094
Debugger [candidate] (6.14 ms) : 0, 6140
Remote Config [baseline] (606.51 µs) : 0, 607
Remote Config [candidate] (591.502 µs) : 0, 592
Telemetry [baseline] (8.37 ms) : 0, 8370
Telemetry [candidate] (8.312 ms) : 0, 8312
section profiling
crashtracking [baseline] (1.443 ms) : 0, 1443
crashtracking [candidate] (1.424 ms) : 0, 1424
BytebuddyAgent [baseline] (767.468 ms) : 0, 767468
BytebuddyAgent [candidate] (760.633 ms) : 0, 760633
GlobalTracer [baseline] (232.946 ms) : 0, 232946
GlobalTracer [candidate] (232.35 ms) : 0, 232350
AppSec [baseline] (30.37 ms) : 0, 30370
AppSec [candidate] (30.435 ms) : 0, 30435
Debugger [baseline] (11.322 ms) : 0, 11322
Debugger [candidate] (7.412 ms) : 0, 7412
Remote Config [baseline] (731.168 µs) : 0, 731
Remote Config [candidate] (705.786 µs) : 0, 706
Telemetry [baseline] (11.871 ms) : 0, 11871
Telemetry [candidate] (15.646 ms) : 0, 15646
ProfilingAgent [baseline] (108.745 ms) : 0, 108745
ProfilingAgent [candidate] (107.568 ms) : 0, 107568
Profiling [baseline] (109.402 ms) : 0, 109402
Profiling [candidate] (108.215 ms) : 0, 108215
LoadParameters
See matching parameters
SummaryFound 0 performance improvements and 2 performance regressions! Performance is the same for 10 metrics, 12 unstable metrics.
Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section baseline
no_agent (35.733 ms) : 35448, 36018
. : milestone, 35733,
appsec (47.709 ms) : 47297, 48121
. : milestone, 47709,
code_origins (45.891 ms) : 45490, 46291
. : milestone, 45891,
iast (43.388 ms) : 43008, 43768
. : milestone, 43388,
profiling (49.196 ms) : 48664, 49727
. : milestone, 49196,
tracing (45.887 ms) : 45497, 46277
. : milestone, 45887,
section candidate
no_agent (37.172 ms) : 36867, 37477
. : milestone, 37172,
appsec (47.63 ms) : 47205, 48055
. : milestone, 47630,
code_origins (44.848 ms) : 44460, 45236
. : milestone, 44848,
iast (46.589 ms) : 46179, 46999
. : milestone, 46589,
profiling (50.126 ms) : 49637, 50615
. : milestone, 50126,
tracing (45.666 ms) : 45285, 46048
. : milestone, 45666,
Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section baseline
no_agent (4.39 ms) : 4340, 4440
. : milestone, 4390,
iast (9.715 ms) : 9555, 9875
. : milestone, 9715,
iast_FULL (14.105 ms) : 13828, 14382
. : milestone, 14105,
iast_GLOBAL (10.584 ms) : 10398, 10769
. : milestone, 10584,
profiling (8.902 ms) : 8753, 9050
. : milestone, 8902,
tracing (7.596 ms) : 7487, 7706
. : milestone, 7596,
section candidate
no_agent (4.426 ms) : 4371, 4480
. : milestone, 4426,
iast (9.489 ms) : 9322, 9656
. : milestone, 9489,
iast_FULL (13.998 ms) : 13720, 14277
. : milestone, 13998,
iast_GLOBAL (10.754 ms) : 10563, 10945
. : milestone, 10754,
profiling (9.08 ms) : 8924, 9237
. : milestone, 9080,
tracing (7.661 ms) : 7553, 7770
. : milestone, 7661,
DacapoParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 11 metrics, 1 unstable metrics. Execution time for biojavagantt
title biojava - execution time [CI 0.99] : candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section baseline
no_agent (15.514 s) : 15514000, 15514000
. : milestone, 15514000,
appsec (14.667 s) : 14667000, 14667000
. : milestone, 14667000,
iast (18.245 s) : 18245000, 18245000
. : milestone, 18245000,
iast_GLOBAL (17.936 s) : 17936000, 17936000
. : milestone, 17936000,
profiling (15.567 s) : 15567000, 15567000
. : milestone, 15567000,
tracing (15.208 s) : 15208000, 15208000
. : milestone, 15208000,
section candidate
no_agent (15.352 s) : 15352000, 15352000
. : milestone, 15352000,
appsec (14.859 s) : 14859000, 14859000
. : milestone, 14859000,
iast (18.468 s) : 18468000, 18468000
. : milestone, 18468000,
iast_GLOBAL (18.117 s) : 18117000, 18117000
. : milestone, 18117000,
profiling (15.62 s) : 15620000, 15620000
. : milestone, 15620000,
tracing (15.247 s) : 15247000, 15247000
. : milestone, 15247000,
Execution time for tomcatgantt
title tomcat - execution time [CI 0.99] : candidate=1.54.0-SNAPSHOT~d5dc373c1d, baseline=1.54.0-SNAPSHOT~9fc16bb0e5
dateFormat X
axisFormat %s
section baseline
no_agent (1.484 ms) : 1472, 1495
. : milestone, 1484,
appsec (3.737 ms) : 3519, 3955
. : milestone, 3737,
iast (2.202 ms) : 2139, 2265
. : milestone, 2202,
iast_GLOBAL (2.243 ms) : 2180, 2306
. : milestone, 2243,
profiling (2.051 ms) : 2000, 2102
. : milestone, 2051,
tracing (2.038 ms) : 1989, 2088
. : milestone, 2038,
section candidate
no_agent (1.48 ms) : 1469, 1492
. : milestone, 1480,
appsec (3.712 ms) : 3495, 3930
. : milestone, 3712,
iast (2.208 ms) : 2145, 2271
. : milestone, 2208,
iast_GLOBAL (2.251 ms) : 2188, 2315
. : milestone, 2251,
profiling (2.053 ms) : 2002, 2104
. : milestone, 2053,
tracing (2.028 ms) : 1979, 2077
. : milestone, 2028,
|
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.
Thanks for having refactored the rum telemetry now pointing to the right set of metrics. The changes looks good. I left some items I'd like to clarify
internal-api/src/main/java/datadog/trace/api/rum/RumInjector.java
Outdated
Show resolved
Hide resolved
internal-api/src/main/java/datadog/trace/api/rum/RumInjectorMetrics.java
Show resolved
Hide resolved
telemetry/src/main/java/datadog/telemetry/rum/RumPeriodicAction.java
Outdated
Show resolved
Hide resolved
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.
Left few comments
🎯 suggestion: Now the development is coming to an end, can you add all the RUM related code to the CODEOWNER files? That includes rum folder from internal module (both test and code) and telemetry files (both code and test too). Thanks!
internal-api/src/main/java/datadog/trace/api/rum/RumInjector.java
Outdated
Show resolved
Hide resolved
internal-api/src/main/java/datadog/trace/api/rum/RumInjectorMetrics.java
Outdated
Show resolved
Hide resolved
internal-api/src/main/java/datadog/trace/api/rum/RumInjectorMetrics.java
Show resolved
Hide resolved
internal-api/src/main/java/datadog/trace/api/rum/RumInjectorMetrics.java
Outdated
Show resolved
Hide resolved
internal-api/src/main/java/datadog/trace/api/rum/RumInjectorMetrics.java
Outdated
Show resolved
Hide resolved
Sounds good. I saw 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.
👏 praise: Thanks for the telemetry fixes and follow up changes!
Sounds good. I saw that /telemetry/ is already under LP, so I added the internal-api rum code + tests there as well. I know official ownership for RUM is still un-confirmed / not under LP, so let me know if I should place these elsewhere.
I was thinking to assign those parts to the @DataDog/rum team 😅 Sorry for not being explicit enough in the first place.
What Does This Do
Refactor RUM telemetry to send telemetry metrics via HTTP instead of StatsDClient UDP.
Motivation
We want metrics to appear in our org, not on the customer side. This PR fixes #9267. See the screenshot below for metrics seen from a test application:

Additional Notes
This was tested by creating an application here, named "Java Injector Test." From there, a sample app was spun up (instructions), and
dd.instrumentation_telemetry_data.rum.injection.initialization.succeed
and other metrics forintegration_name:servlet
were checked for on the Metrics Explorer page.Contributor Checklist
type:
and (comp:
orinst:
) labels in addition to any usefull labelsclose
,fix
or any linking keywords when referencing an issue.Use
solves
instead, and assign the PR milestone to the issueJira ticket: https://datadoghq.atlassian.net/browse/LANGPLAT-679