-
Notifications
You must be signed in to change notification settings - Fork 292
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
Propagate module context from build system process to child JVM processes #7710
Propagate module context from build system process to child JVM processes #7710
Conversation
BenchmarksStartupParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 51 metrics, 12 unstable metrics. Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.078 s) : 0, 1078335
Total [baseline] (10.431 s) : 0, 10431135
Agent [candidate] (1.072 s) : 0, 1071920
Total [candidate] (10.461 s) : 0, 10460703
section appsec
Agent [baseline] (1.206 s) : 0, 1205511
Total [baseline] (10.66 s) : 0, 10660311
Agent [candidate] (1.21 s) : 0, 1209717
Total [candidate] (10.624 s) : 0, 10624201
section iast
Agent [baseline] (1.208 s) : 0, 1207767
Total [baseline] (10.912 s) : 0, 10912287
Agent [candidate] (1.199 s) : 0, 1199339
Total [candidate] (10.914 s) : 0, 10913663
section profiling
Agent [baseline] (1.273 s) : 0, 1273081
Total [baseline] (10.675 s) : 0, 10675322
Agent [candidate] (1.278 s) : 0, 1278372
Total [candidate] (10.7 s) : 0, 10700109
gantt
title petclinic - break down per module: candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (688.239 ms) : 0, 688239
BytebuddyAgent [candidate] (683.751 ms) : 0, 683751
GlobalTracer [baseline] (313.412 ms) : 0, 313412
GlobalTracer [candidate] (312.12 ms) : 0, 312120
AppSec [baseline] (54.354 ms) : 0, 54354
AppSec [candidate] (53.904 ms) : 0, 53904
Remote Config [baseline] (669.977 µs) : 0, 670
Remote Config [candidate] (664.228 µs) : 0, 664
Telemetry [baseline] (7.759 ms) : 0, 7759
Telemetry [candidate] (7.695 ms) : 0, 7695
section appsec
BytebuddyAgent [baseline] (700.416 ms) : 0, 700416
BytebuddyAgent [candidate] (702.875 ms) : 0, 702875
GlobalTracer [baseline] (308.525 ms) : 0, 308525
GlobalTracer [candidate] (309.283 ms) : 0, 309283
AppSec [baseline] (162.955 ms) : 0, 162955
AppSec [candidate] (163.862 ms) : 0, 163862
IAST [baseline] (20.529 ms) : 0, 20529
IAST [candidate] (20.566 ms) : 0, 20566
Remote Config [baseline] (637.226 µs) : 0, 637
Remote Config [candidate] (638.058 µs) : 0, 638
Telemetry [baseline] (8.913 ms) : 0, 8913
Telemetry [candidate] (8.916 ms) : 0, 8916
section iast
BytebuddyAgent [baseline] (805.172 ms) : 0, 805172
BytebuddyAgent [candidate] (798.593 ms) : 0, 798593
GlobalTracer [baseline] (302.959 ms) : 0, 302959
GlobalTracer [candidate] (301.08 ms) : 0, 301080
AppSec [baseline] (56.258 ms) : 0, 56258
AppSec [candidate] (54.635 ms) : 0, 54635
IAST [baseline] (21.606 ms) : 0, 21606
IAST [candidate] (23.553 ms) : 0, 23553
Remote Config [baseline] (625.612 µs) : 0, 626
Remote Config [candidate] (611.678 µs) : 0, 612
Telemetry [baseline] (7.266 ms) : 0, 7266
Telemetry [candidate] (7.048 ms) : 0, 7048
section profiling
BytebuddyAgent [baseline] (677.654 ms) : 0, 677654
BytebuddyAgent [candidate] (680.647 ms) : 0, 680647
GlobalTracer [baseline] (395.801 ms) : 0, 395801
GlobalTracer [candidate] (397.952 ms) : 0, 397952
AppSec [baseline] (54.877 ms) : 0, 54877
AppSec [candidate] (54.841 ms) : 0, 54841
Remote Config [baseline] (675.759 µs) : 0, 676
Remote Config [candidate] (654.925 µs) : 0, 655
Telemetry [baseline] (7.494 ms) : 0, 7494
Telemetry [candidate] (7.541 ms) : 0, 7541
ProfilingAgent [baseline] (97.621 ms) : 0, 97621
ProfilingAgent [candidate] (97.541 ms) : 0, 97541
Profiling [baseline] (97.645 ms) : 0, 97645
Profiling [candidate] (97.565 ms) : 0, 97565
Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.072 s) : 0, 1071855
Total [baseline] (8.575 s) : 0, 8574648
Agent [candidate] (1.07 s) : 0, 1070378
Total [candidate] (8.574 s) : 0, 8573792
section iast
Agent [baseline] (1.2 s) : 0, 1199903
Total [baseline] (9.077 s) : 0, 9076960
Agent [candidate] (1.2 s) : 0, 1200294
Total [candidate] (9.099 s) : 0, 9098568
section iast_HARDCODED_SECRET_DISABLED
Agent [baseline] (1.2 s) : 0, 1199746
Total [baseline] (9.096 s) : 0, 9095687
Agent [candidate] (1.203 s) : 0, 1202550
Total [candidate] (9.103 s) : 0, 9102553
section iast_TELEMETRY_OFF
Agent [baseline] (1.199 s) : 0, 1198501
Total [baseline] (9.132 s) : 0, 9132247
Agent [candidate] (1.194 s) : 0, 1194143
Total [candidate] (9.07 s) : 0, 9070435
gantt
title insecure-bank - break down per module: candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (684.688 ms) : 0, 684688
BytebuddyAgent [candidate] (682.484 ms) : 0, 682484
GlobalTracer [baseline] (311.363 ms) : 0, 311363
GlobalTracer [candidate] (311.849 ms) : 0, 311849
AppSec [baseline] (53.77 ms) : 0, 53770
AppSec [candidate] (53.931 ms) : 0, 53931
Remote Config [baseline] (653.988 µs) : 0, 654
Remote Config [candidate] (663.019 µs) : 0, 663
Telemetry [baseline] (7.588 ms) : 0, 7588
Telemetry [candidate] (7.676 ms) : 0, 7676
section iast
BytebuddyAgent [baseline] (798.587 ms) : 0, 798587
BytebuddyAgent [candidate] (799.208 ms) : 0, 799208
GlobalTracer [baseline] (301.179 ms) : 0, 301179
GlobalTracer [candidate] (301.237 ms) : 0, 301237
AppSec [baseline] (53.354 ms) : 0, 53354
AppSec [candidate] (54.123 ms) : 0, 54123
IAST [baseline] (24.434 ms) : 0, 24434
IAST [candidate] (24.23 ms) : 0, 24230
Remote Config [baseline] (611.966 µs) : 0, 612
Remote Config [candidate] (596.803 µs) : 0, 597
Telemetry [baseline] (7.907 ms) : 0, 7907
Telemetry [candidate] (7.055 ms) : 0, 7055
section iast_HARDCODED_SECRET_DISABLED
BytebuddyAgent [baseline] (798.337 ms) : 0, 798337
BytebuddyAgent [candidate] (800.609 ms) : 0, 800609
GlobalTracer [baseline] (301.21 ms) : 0, 301210
GlobalTracer [candidate] (301.929 ms) : 0, 301929
AppSec [baseline] (54.925 ms) : 0, 54925
AppSec [candidate] (55.541 ms) : 0, 55541
IAST [baseline] (22.86 ms) : 0, 22860
IAST [candidate] (22.875 ms) : 0, 22875
Remote Config [baseline] (613.808 µs) : 0, 614
Remote Config [candidate] (605.277 µs) : 0, 605
Telemetry [baseline] (7.901 ms) : 0, 7901
Telemetry [candidate] (7.072 ms) : 0, 7072
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (797.524 ms) : 0, 797524
BytebuddyAgent [candidate] (793.772 ms) : 0, 793772
GlobalTracer [baseline] (300.749 ms) : 0, 300749
GlobalTracer [candidate] (300.698 ms) : 0, 300698
AppSec [baseline] (55.843 ms) : 0, 55843
AppSec [candidate] (55.038 ms) : 0, 55038
IAST [baseline] (22.798 ms) : 0, 22798
IAST [candidate] (23.243 ms) : 0, 23243
Remote Config [baseline] (611.905 µs) : 0, 612
Remote Config [candidate] (607.173 µs) : 0, 607
Telemetry [baseline] (7.085 ms) : 0, 7085
Telemetry [candidate] (6.947 ms) : 0, 6947
LoadParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 13 metrics, 15 unstable metrics. Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section baseline
no_agent (1.375 ms) : 1354, 1395
. : milestone, 1375,
appsec (1.73 ms) : 1707, 1753
. : milestone, 1730,
appsec_no_iast (1.738 ms) : 1714, 1762
. : milestone, 1738,
iast (1.487 ms) : 1464, 1510
. : milestone, 1487,
profiling (1.483 ms) : 1459, 1507
. : milestone, 1483,
tracing (1.487 ms) : 1463, 1511
. : milestone, 1487,
section candidate
no_agent (1.343 ms) : 1324, 1363
. : milestone, 1343,
appsec (1.725 ms) : 1702, 1748
. : milestone, 1725,
appsec_no_iast (1.749 ms) : 1725, 1773
. : milestone, 1749,
iast (1.499 ms) : 1476, 1522
. : milestone, 1499,
profiling (1.49 ms) : 1465, 1515
. : milestone, 1490,
tracing (1.463 ms) : 1439, 1488
. : milestone, 1463,
Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section baseline
no_agent (374.229 µs) : 354, 394
. : milestone, 374,
iast (486.541 µs) : 465, 508
. : milestone, 487,
iast_FULL (562.977 µs) : 541, 584
. : milestone, 563,
iast_GLOBAL (518.913 µs) : 497, 541
. : milestone, 519,
iast_HARDCODED_SECRET_DISABLED (485.071 µs) : 464, 506
. : milestone, 485,
iast_INACTIVE (452.119 µs) : 431, 473
. : milestone, 452,
iast_TELEMETRY_OFF (480.136 µs) : 458, 502
. : milestone, 480,
tracing (450.012 µs) : 429, 471
. : milestone, 450,
section candidate
no_agent (372.876 µs) : 353, 393
. : milestone, 373,
iast (495.019 µs) : 474, 516
. : milestone, 495,
iast_FULL (559.708 µs) : 538, 581
. : milestone, 560,
iast_GLOBAL (511.47 µs) : 490, 533
. : milestone, 511,
iast_HARDCODED_SECRET_DISABLED (492.879 µs) : 471, 514
. : milestone, 493,
iast_INACTIVE (451.453 µs) : 431, 472
. : milestone, 451,
iast_TELEMETRY_OFF (480.839 µs) : 459, 503
. : milestone, 481,
tracing (440.791 µs) : 421, 461
. : milestone, 441,
DacapoParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 12 metrics, 0 unstable metrics. Execution time for biojavagantt
title biojava - execution time [CI 0.99] : candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section baseline
no_agent (15.487 s) : 15487000, 15487000
. : milestone, 15487000,
appsec (15.143 s) : 15143000, 15143000
. : milestone, 15143000,
iast (18.81 s) : 18810000, 18810000
. : milestone, 18810000,
iast_GLOBAL (17.891 s) : 17891000, 17891000
. : milestone, 17891000,
profiling (15.125 s) : 15125000, 15125000
. : milestone, 15125000,
tracing (15.027 s) : 15027000, 15027000
. : milestone, 15027000,
section candidate
no_agent (15.067 s) : 15067000, 15067000
. : milestone, 15067000,
appsec (15.084 s) : 15084000, 15084000
. : milestone, 15084000,
iast (18.81 s) : 18810000, 18810000
. : milestone, 18810000,
iast_GLOBAL (17.849 s) : 17849000, 17849000
. : milestone, 17849000,
profiling (15.483 s) : 15483000, 15483000
. : milestone, 15483000,
tracing (14.988 s) : 14988000, 14988000
. : milestone, 14988000,
Execution time for tomcatgantt
title tomcat - execution time [CI 0.99] : candidate=1.41.0-SNAPSHOT~73dae75284, baseline=1.41.0-SNAPSHOT~919bf01a5f
dateFormat X
axisFormat %s
section baseline
no_agent (1.469 ms) : 1457, 1481
. : milestone, 1469,
appsec (2.34 ms) : 2299, 2381
. : milestone, 2340,
iast (2.058 ms) : 2007, 2109
. : milestone, 2058,
iast_GLOBAL (2.1 ms) : 2049, 2152
. : milestone, 2100,
profiling (1.933 ms) : 1892, 1975
. : milestone, 1933,
tracing (1.915 ms) : 1875, 1955
. : milestone, 1915,
section candidate
no_agent (1.471 ms) : 1459, 1482
. : milestone, 1471,
appsec (2.318 ms) : 2277, 2359
. : milestone, 2318,
iast (2.085 ms) : 2032, 2138
. : milestone, 2085,
iast_GLOBAL (2.121 ms) : 2069, 2173
. : milestone, 2121,
profiling (1.937 ms) : 1895, 1979
. : milestone, 1937,
tracing (1.897 ms) : 1859, 1936
. : milestone, 1897,
|
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.
Quick question: how does this work with 128-bit Trace IDs as you are using span.getTraceId().toLong()
which drop the high 64-bit of the TID?
Another think I wonder too is if a propagator getter, based on system property, and setter, based on process builder? or map?, should not be added as part of the propagation API 🤷 -- It could be in a later PR though but I find it helpful and particularly tied to a product
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.
Following internal discussion, LGTM for Platform / Core 👍
What Does This Do
Adds propagation of the context of the build system module span from the parent process (build system) to children processes (JVMs forked to run tests).
Motivation
Adding support for suite setup/teardown tracing.
Any APM span (that is a span that is not a test suite or a test case) started in a child process needs to have test session ID as the trace ID, in order to be displayed properly in Datadog.
The only way to set the trace ID of a span is to provide parent context when creating that span.
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: SDTEST-970