Skip to content

Rework Kotlin coroutines instrumentation around coroutine context - #8774

Merged
mcculls merged 1 commit into
masterfrom
mcculls/rework-kotlin-instrumentation
May 12, 2025
Merged

Rework Kotlin coroutines instrumentation around coroutine context#8774
mcculls merged 1 commit into
masterfrom
mcculls/rework-kotlin-instrumentation

Conversation

@mcculls

@mccullsmcculls commented May 6, 2025

Copy link
Copy Markdown
Contributor

What Does This Do

The previous approach associated the scope state with the job (coroutine) instance using field-injection. However this doesn't work when the coroutine instance might be recreated or wrapped by something else.

This new approach creates a DatadogThreadContextElement for every coroutine context created. The scope state is then lazily captured within this element: either after non-lazy coroutines are constructed, when lazy coroutines start, or failing that when the element is first used to update the thread context.

At the same time it captures the active span using a continuation to avoid the trace from completing before the coroutine is complete. Note there is no need to (re)activate the continuation when switching contexts because we have already captured the scope state.

Motivation

This simpler instrumentation will be easier to move over to the new Context API

This also fixes the scenario described in https://github.com/arun-rama/KotlinCoroutineTracingIssueRepro/tree/main

Additional Notes

As an added benefit, this approach does not require field injection

Contributor Checklist

Jira ticket: AIDM-602

@mccullsmcculls added tag: do not merge Do not merge changes type: refactoring inst: kotlin Kotlin instrumentation labels May 6, 2025
@pr-commenter

pr-commenterBot commented May 6, 2025

Copy link
Copy Markdown

Benchmarks

Startup

Parameters

BaselineCandidate
baseline_or_candidatebaselinecandidate
git_branchmastermcculls/rework-kotlin-instrumentation
git_commit_date17468258211746995032
git_commit_shaf494c3391445ae
release_version1.50.0-SNAPSHOT~f494c33b011.50.0-SNAPSHOT~91445aea2f
See matching parameters
BaselineCandidate
applicationinsecure-bankinsecure-bank
ci_job_date17469974461746997446
ci_job_id932726370932726370
ci_pipeline_id6473415664734156
cpu_modelIntel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHzIntel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
kernel_versionLinux runner-i83qnnyx-project-304-concurrent-1-9h633128 6.8.0-1027-aws #29~22.04.1-Ubuntu SMP Sun Mar 30 07:45:38 UTC 2025 x86_64 x86_64 x86_64 GNU/LinuxLinux runner-i83qnnyx-project-304-concurrent-1-9h633128 6.8.0-1027-aws #29~22.04.1-Ubuntu SMP Sun Mar 30 07:45:38 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
moduleAgentAgent
parentNoneNone
variantiastiast

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 59 metrics, 12 unstable metrics.

Startup time reports for petclinic
gantt
title petclinic - global startup overhead: candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.023 s) : 0, 1023211
Total [baseline] (10.479 s) : 0, 10479305
Agent [candidate] (1.018 s) : 0, 1018140
Total [candidate] (10.494 s) : 0, 10493633
section appsec
Agent [baseline] (1.157 s) : 0, 1157173
Total [baseline] (10.653 s) : 0, 10653479
Agent [candidate] (1.161 s) : 0, 1160889
Total [candidate] (10.634 s) : 0, 10634415
section iast
Agent [baseline] (1.147 s) : 0, 1146691
Total [baseline] (10.867 s) : 0, 10867323
Agent [candidate] (1.146 s) : 0, 1146259
Total [candidate] (10.93 s) : 0, 10929681
section profiling
Agent [baseline] (1.281 s) : 0, 1280534
Total [baseline] (10.898 s) : 0, 10898256
Agent [candidate] (1.28 s) : 0, 1279562
Total [candidate] (10.807 s) : 0, 10807447
Loading
  • baseline results
ModuleVariantDurationΔ tracing
Agenttracing1.023 s-
Agentappsec1.157 s133.962 ms (13.1%)
Agentiast1.147 s123.48 ms (12.1%)
Agentprofiling1.281 s257.323 ms (25.1%)
Totaltracing10.479 s-
Totalappsec10.653 s174.174 ms (1.7%)
Totaliast10.867 s388.019 ms (3.7%)
Totalprofiling10.898 s418.951 ms (4.0%)
  • candidate results
ModuleVariantDurationΔ tracing
Agenttracing1.018 s-
Agentappsec1.161 s142.749 ms (14.0%)
Agentiast1.146 s128.119 ms (12.6%)
Agentprofiling1.28 s261.422 ms (25.7%)
Totaltracing10.494 s-
Totalappsec10.634 s140.782 ms (1.3%)
Totaliast10.93 s436.048 ms (4.2%)
Totalprofiling10.807 s313.813 ms (3.0%)
gantt
title petclinic - break down per module: candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (685.953 ms) : 0, 685953
BytebuddyAgent [candidate] (681.773 ms) : 0, 681773
GlobalTracer [baseline] (240.971 ms) : 0, 240971
GlobalTracer [candidate] (239.794 ms) : 0, 239794
AppSec [baseline] (54.627 ms) : 0, 54627
AppSec [candidate] (54.479 ms) : 0, 54479
Debugger [baseline] (8.962 ms) : 0, 8962
Debugger [candidate] (8.192 ms) : 0, 8192
Remote Config [baseline] (691.447 µs) : 0, 691
Remote Config [candidate] (694.489 µs) : 0, 694
Telemetry [baseline] (8.343 ms) : 0, 8343
Telemetry [candidate] (9.696 ms) : 0, 9696
section appsec
BytebuddyAgent [baseline] (698.813 ms) : 0, 698813
BytebuddyAgent [candidate] (700.179 ms) : 0, 700179
GlobalTracer [baseline] (235.887 ms) : 0, 235887
GlobalTracer [candidate] (236.585 ms) : 0, 236585
AppSec [baseline] (174.151 ms) : 0, 174151
AppSec [candidate] (175.858 ms) : 0, 175858
Debugger [baseline] (5.943 ms) : 0, 5943
Debugger [candidate] (5.957 ms) : 0, 5957
Remote Config [baseline] (618.861 µs) : 0, 619
Remote Config [candidate] (631.117 µs) : 0, 631
Telemetry [baseline] (7.411 ms) : 0, 7411
Telemetry [candidate] (7.418 ms) : 0, 7418
IAST [baseline] (21.673 ms) : 0, 21673
IAST [candidate] (21.635 ms) : 0, 21635
section iast
BytebuddyAgent [baseline] (800.43 ms) : 0, 800430
BytebuddyAgent [candidate] (800.101 ms) : 0, 800101
GlobalTracer [baseline] (230.077 ms) : 0, 230077
GlobalTracer [candidate] (230.244 ms) : 0, 230244
AppSec [baseline] (52.0 ms) : 0, 52000
AppSec [candidate] (48.499 ms) : 0, 48499
Debugger [baseline] (5.902 ms) : 0, 5902
Debugger [candidate] (5.859 ms) : 0, 5859
Remote Config [baseline] (594.637 µs) : 0, 595
Remote Config [candidate] (591.026 µs) : 0, 591
Telemetry [baseline] (7.87 ms) : 0, 7870
Telemetry [candidate] (7.879 ms) : 0, 7879
IAST [baseline] (26.435 ms) : 0, 26435
IAST [candidate] (29.686 ms) : 0, 29686
section profiling
BytebuddyAgent [baseline] (673.276 ms) : 0, 673276
BytebuddyAgent [candidate] (672.336 ms) : 0, 672336
GlobalTracer [baseline] (378.533 ms) : 0, 378533
GlobalTracer [candidate] (378.532 ms) : 0, 378532
AppSec [baseline] (54.242 ms) : 0, 54242
AppSec [candidate] (53.949 ms) : 0, 53949
Debugger [baseline] (6.085 ms) : 0, 6085
Debugger [candidate] (6.165 ms) : 0, 6165
Remote Config [baseline] (645.496 µs) : 0, 645
Remote Config [candidate] (651.493 µs) : 0, 651
Telemetry [baseline] (8.089 ms) : 0, 8089
Telemetry [candidate] (8.121 ms) : 0, 8121
ProfilingAgent [baseline] (109.069 ms) : 0, 109069
ProfilingAgent [candidate] (109.283 ms) : 0, 109283
Profiling [baseline] (109.094 ms) : 0, 109094
Profiling [candidate] (109.309 ms) : 0, 109309
Loading
Startup time reports for insecure-bank
gantt
title insecure-bank - global startup overhead: candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.029 s) : 0, 1028787
Total [baseline] (8.633 s) : 0, 8633479
Agent [candidate] (1.019 s) : 0, 1018982
Total [candidate] (8.645 s) : 0, 8645096
section iast
Agent [baseline] (1.146 s) : 0, 1145648
Total [baseline] (9.188 s) : 0, 9188155
Agent [candidate] (1.147 s) : 0, 1146884
Total [candidate] (9.2 s) : 0, 9199738
section iast_HARDCODED_SECRET_DISABLED
Agent [baseline] (1.147 s) : 0, 1147246
Total [baseline] (9.227 s) : 0, 9227232
Agent [candidate] (1.153 s) : 0, 1153361
Total [candidate] (9.205 s) : 0, 9205317
section iast_TELEMETRY_OFF
Agent [baseline] (1.161 s) : 0, 1161068
Total [baseline] (9.266 s) : 0, 9266352
Agent [candidate] (1.144 s) : 0, 1143715
Total [candidate] (9.196 s) : 0, 9196216
Loading
  • baseline results
ModuleVariantDurationΔ tracing
Agenttracing1.029 s-
Agentiast1.146 s116.861 ms (11.4%)
Agentiast_HARDCODED_SECRET_DISABLED1.147 s118.459 ms (11.5%)
Agentiast_TELEMETRY_OFF1.161 s132.281 ms (12.9%)
Totaltracing8.633 s-
Totaliast9.188 s554.676 ms (6.4%)
Totaliast_HARDCODED_SECRET_DISABLED9.227 s593.753 ms (6.9%)
Totaliast_TELEMETRY_OFF9.266 s632.872 ms (7.3%)
  • candidate results
ModuleVariantDurationΔ tracing
Agenttracing1.019 s-
Agentiast1.147 s127.901 ms (12.6%)
Agentiast_HARDCODED_SECRET_DISABLED1.153 s134.379 ms (13.2%)
Agentiast_TELEMETRY_OFF1.144 s124.733 ms (12.2%)
Totaltracing8.645 s-
Totaliast9.2 s554.642 ms (6.4%)
Totaliast_HARDCODED_SECRET_DISABLED9.205 s560.221 ms (6.5%)
Totaliast_TELEMETRY_OFF9.196 s551.119 ms (6.4%)
gantt
title insecure-bank - break down per module: candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (688.943 ms) : 0, 688943
BytebuddyAgent [candidate] (680.45 ms) : 0, 680450
GlobalTracer [baseline] (241.699 ms) : 0, 241699
GlobalTracer [candidate] (239.245 ms) : 0, 239245
AppSec [baseline] (55.7 ms) : 0, 55700
AppSec [candidate] (54.81 ms) : 0, 54810
Debugger [baseline] (8.311 ms) : 0, 8311
Debugger [candidate] (10.569 ms) : 0, 10569
Remote Config [baseline] (694.674 µs) : 0, 695
Remote Config [candidate] (686.604 µs) : 0, 687
Telemetry [baseline] (9.774 ms) : 0, 9774
Telemetry [candidate] (9.684 ms) : 0, 9684
section iast
BytebuddyAgent [baseline] (799.644 ms) : 0, 799644
BytebuddyAgent [candidate] (800.234 ms) : 0, 800234
GlobalTracer [baseline] (229.688 ms) : 0, 229688
GlobalTracer [candidate] (230.279 ms) : 0, 230279
AppSec [baseline] (50.279 ms) : 0, 50279
AppSec [candidate] (51.079 ms) : 0, 51079
Debugger [baseline] (5.907 ms) : 0, 5907
Debugger [candidate] (5.906 ms) : 0, 5906
Remote Config [baseline] (584.316 µs) : 0, 584
Remote Config [candidate] (606.098 µs) : 0, 606
Telemetry [baseline] (7.845 ms) : 0, 7845
Telemetry [candidate] (7.906 ms) : 0, 7906
IAST [baseline] (28.171 ms) : 0, 28171
IAST [candidate] (24.322 ms) : 0, 24322
section iast_HARDCODED_SECRET_DISABLED
BytebuddyAgent [baseline] (801.014 ms) : 0, 801014
BytebuddyAgent [candidate] (804.888 ms) : 0, 804888
GlobalTracer [baseline] (230.219 ms) : 0, 230219
GlobalTracer [candidate] (231.627 ms) : 0, 231627
AppSec [baseline] (48.567 ms) : 0, 48567
AppSec [candidate] (48.688 ms) : 0, 48688
Debugger [baseline] (5.853 ms) : 0, 5853
Debugger [candidate] (5.941 ms) : 0, 5941
Remote Config [baseline] (579.168 µs) : 0, 579
Remote Config [candidate] (586.448 µs) : 0, 586
Telemetry [baseline] (7.843 ms) : 0, 7843
Telemetry [candidate] (8.011 ms) : 0, 8011
IAST [baseline] (29.696 ms) : 0, 29696
IAST [candidate] (30.084 ms) : 0, 30084
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (810.262 ms) : 0, 810262
BytebuddyAgent [candidate] (796.787 ms) : 0, 796787
GlobalTracer [baseline] (232.98 ms) : 0, 232980
GlobalTracer [candidate] (230.833 ms) : 0, 230833
AppSec [baseline] (54.19 ms) : 0, 54190
AppSec [candidate] (53.319 ms) : 0, 53319
Debugger [baseline] (6.083 ms) : 0, 6083
Debugger [candidate] (5.991 ms) : 0, 5991
Remote Config [baseline] (617.799 µs) : 0, 618
Remote Config [candidate] (608.084 µs) : 0, 608
Telemetry [baseline] (7.952 ms) : 0, 7952
Telemetry [candidate] (7.858 ms) : 0, 7858
IAST [baseline] (25.156 ms) : 0, 25156
IAST [candidate] (24.847 ms) : 0, 24847
Loading

Load

Parameters

BaselineCandidate
baseline_or_candidatebaselinecandidate
end_time2025-05-11T20:34:282025-05-11T20:42:10
git_branchmastermcculls/rework-kotlin-instrumentation
git_commit_date17468258211746995032
git_commit_shaf494c3391445ae
release_version1.50.0-SNAPSHOT~f494c33b011.50.0-SNAPSHOT~91445aea2f
start_time2025-05-11T20:34:142025-05-11T20:41:56
See matching parameters
BaselineCandidate
applicationinsecure-bankinsecure-bank
ci_job_date17469965271746996527
ci_job_id932726371932726371
ci_pipeline_id6473415664734156
cpu_modelIntel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHzIntel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
kernel_versionLinux runner-psrqmy6d-project-304-concurrent-0-kpb4347j 6.8.0-1027-aws #29~22.04.1-Ubuntu SMP Sun Mar 30 07:45:38 UTC 2025 x86_64 x86_64 x86_64 GNU/LinuxLinux runner-psrqmy6d-project-304-concurrent-0-kpb4347j 6.8.0-1027-aws #29~22.04.1-Ubuntu SMP Sun Mar 30 07:45:38 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
variantiastiast

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 12 metrics, 18 unstable metrics.

Request duration reports for insecure-bank
gantt
title insecure-bank - request duration [CI 0.99] : candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section baseline
no_agent (381.245 µs) : 362, 401
. : milestone, 381,
iast (530.203 µs) : 507, 553
. : milestone, 530,
iast_FULL (724.13 µs) : 702, 746
. : milestone, 724,
iast_GLOBAL (553.688 µs) : 532, 575
. : milestone, 554,
iast_HARDCODED_SECRET_DISABLED (516.875 µs) : 494, 539
. : milestone, 517,
iast_INACTIVE (455.373 µs) : 434, 476
. : milestone, 455,
iast_TELEMETRY_OFF (510.831 µs) : 487, 534
. : milestone, 511,
tracing (463.084 µs) : 441, 485
. : milestone, 463,
section candidate
no_agent (385.554 µs) : 366, 405
. : milestone, 386,
iast (513.126 µs) : 491, 535
. : milestone, 513,
iast_FULL (740.995 µs) : 719, 763
. : milestone, 741,
iast_GLOBAL (562.872 µs) : 540, 585
. : milestone, 563,
iast_HARDCODED_SECRET_DISABLED (522.818 µs) : 500, 546
. : milestone, 523,
iast_INACTIVE (465.449 µs) : 443, 488
. : milestone, 465,
iast_TELEMETRY_OFF (510.316 µs) : 487, 533
. : milestone, 510,
tracing (457.472 µs) : 435, 480
. : milestone, 457,
Loading
  • baseline results
VariantRequest duration [CI 0.99]Δ no_agent
no_agent381.245 µs [361.677 µs, 400.813 µs]-
iast530.203 µs [506.996 µs, 553.41 µs]148.958 µs (39.1%)
iast_FULL724.13 µs [702.19 µs, 746.071 µs]342.885 µs (89.9%)
iast_GLOBAL553.688 µs [532.17 µs, 575.207 µs]172.443 µs (45.2%)
iast_HARDCODED_SECRET_DISABLED516.875 µs [494.441 µs, 539.309 µs]135.63 µs (35.6%)
iast_INACTIVE455.373 µs [434.403 µs, 476.344 µs]74.128 µs (19.4%)
iast_TELEMETRY_OFF510.831 µs [487.475 µs, 534.186 µs]129.586 µs (34.0%)
tracing463.084 µs [440.839 µs, 485.329 µs]81.839 µs (21.5%)
  • candidate results
VariantRequest duration [CI 0.99]Δ no_agent
no_agent385.554 µs [365.728 µs, 405.38 µs]-
iast513.126 µs [491.38 µs, 534.872 µs]127.572 µs (33.1%)
iast_FULL740.995 µs [718.958 µs, 763.031 µs]355.441 µs (92.2%)
iast_GLOBAL562.872 µs [540.31 µs, 585.435 µs]177.318 µs (46.0%)
iast_HARDCODED_SECRET_DISABLED522.818 µs [499.641 µs, 545.995 µs]137.264 µs (35.6%)
iast_INACTIVE465.449 µs [442.796 µs, 488.102 µs]79.895 µs (20.7%)
iast_TELEMETRY_OFF510.316 µs [487.17 µs, 533.462 µs]124.762 µs (32.4%)
tracing457.472 µs [435.386 µs, 479.558 µs]71.918 µs (18.7%)
Request duration reports for petclinic
gantt
title petclinic - request duration [CI 0.99] : candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section baseline
no_agent (1.359 ms) : 1340, 1378
. : milestone, 1359,
appsec (1.742 ms) : 1718, 1765
. : milestone, 1742,
appsec_no_iast (1.732 ms) : 1709, 1754
. : milestone, 1732,
code_origins (1.643 ms) : 1617, 1669
. : milestone, 1643,
iast (1.509 ms) : 1485, 1533
. : milestone, 1509,
profiling (1.521 ms) : 1496, 1546
. : milestone, 1521,
tracing (1.484 ms) : 1459, 1509
. : milestone, 1484,
section candidate
no_agent (1.366 ms) : 1347, 1385
. : milestone, 1366,
appsec (1.749 ms) : 1726, 1773
. : milestone, 1749,
appsec_no_iast (1.708 ms) : 1684, 1732
. : milestone, 1708,
code_origins (1.68 ms) : 1652, 1708
. : milestone, 1680,
iast (1.52 ms) : 1497, 1544
. : milestone, 1520,
profiling (1.527 ms) : 1503, 1550
. : milestone, 1527,
tracing (1.507 ms) : 1482, 1532
. : milestone, 1507,
Loading
  • baseline results
VariantRequest duration [CI 0.99]Δ no_agent
no_agent1.359 ms [1.34 ms, 1.378 ms]-
appsec1.742 ms [1.718 ms, 1.765 ms]382.301 µs (28.1%)
appsec_no_iast1.732 ms [1.709 ms, 1.754 ms]372.345 µs (27.4%)
code_origins1.643 ms [1.617 ms, 1.669 ms]283.951 µs (20.9%)
iast1.509 ms [1.485 ms, 1.533 ms]149.884 µs (11.0%)
profiling1.521 ms [1.496 ms, 1.546 ms]161.605 µs (11.9%)
tracing1.484 ms [1.459 ms, 1.509 ms]124.7 µs (9.2%)
  • candidate results
VariantRequest duration [CI 0.99]Δ no_agent
no_agent1.366 ms [1.347 ms, 1.385 ms]-
appsec1.749 ms [1.726 ms, 1.773 ms]383.611 µs (28.1%)
appsec_no_iast1.708 ms [1.684 ms, 1.732 ms]342.24 µs (25.1%)
code_origins1.68 ms [1.652 ms, 1.708 ms]314.468 µs (23.0%)
iast1.52 ms [1.497 ms, 1.544 ms]154.51 µs (11.3%)
profiling1.527 ms [1.503 ms, 1.55 ms]161.088 µs (11.8%)
tracing1.507 ms [1.482 ms, 1.532 ms]141.465 µs (10.4%)

Dacapo

Parameters

BaselineCandidate
baseline_or_candidatebaselinecandidate
git_branchmastermcculls/rework-kotlin-instrumentation
git_commit_date17468258211746995032
git_commit_shaf494c3391445ae
release_version1.50.0-SNAPSHOT~f494c33b011.50.0-SNAPSHOT~91445aea2f
See matching parameters
BaselineCandidate
applicationbiojavabiojava
ci_job_date17469969721746996972
ci_job_id932726372932726372
ci_pipeline_id6473415664734156
cpu_modelIntel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHzIntel(R) Xeon(R) Platinum 8259CL CPU @ 2.50GHz
kernel_versionLinux runner-i83qnnyx-project-304-concurrent-2-1mg3z1um 6.8.0-1027-aws #29~22.04.1-Ubuntu SMP Sun Mar 30 07:45:38 UTC 2025 x86_64 x86_64 x86_64 GNU/LinuxLinux runner-i83qnnyx-project-304-concurrent-2-1mg3z1um 6.8.0-1027-aws #29~22.04.1-Ubuntu SMP Sun Mar 30 07:45:38 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
variantappsecappsec

Summary

Found 0 performance improvements and 0 performance regressions! Performance is the same for 12 metrics, 0 unstable metrics.

Execution time for biojava
gantt
title biojava - execution time [CI 0.99] : candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section baseline
no_agent (15.417 s) : 15417000, 15417000
. : milestone, 15417000,
appsec (15.092 s) : 15092000, 15092000
. : milestone, 15092000,
iast (19.075 s) : 19075000, 19075000
. : milestone, 19075000,
iast_GLOBAL (18.188 s) : 18188000, 18188000
. : milestone, 18188000,
profiling (15.652 s) : 15652000, 15652000
. : milestone, 15652000,
tracing (14.921 s) : 14921000, 14921000
. : milestone, 14921000,
section candidate
no_agent (14.962 s) : 14962000, 14962000
. : milestone, 14962000,
appsec (15.146 s) : 15146000, 15146000
. : milestone, 15146000,
iast (18.987 s) : 18987000, 18987000
. : milestone, 18987000,
iast_GLOBAL (18.003 s) : 18003000, 18003000
. : milestone, 18003000,
profiling (15.502 s) : 15502000, 15502000
. : milestone, 15502000,
tracing (15.045 s) : 15045000, 15045000
. : milestone, 15045000,
Loading
  • baseline results
VariantExecution Time [CI 0.99]Δ no_agent
no_agent15.417 s [15.417 s, 15.417 s]-
appsec15.092 s [15.092 s, 15.092 s]-325.0 ms (-2.1%)
iast19.075 s [19.075 s, 19.075 s]3.658 s (23.7%)
iast_GLOBAL18.188 s [18.188 s, 18.188 s]2.771 s (18.0%)
profiling15.652 s [15.652 s, 15.652 s]235.0 ms (1.5%)
tracing14.921 s [14.921 s, 14.921 s]-496.0 ms (-3.2%)
  • candidate results
VariantExecution Time [CI 0.99]Δ no_agent
no_agent14.962 s [14.962 s, 14.962 s]-
appsec15.146 s [15.146 s, 15.146 s]184.0 ms (1.2%)
iast18.987 s [18.987 s, 18.987 s]4.025 s (26.9%)
iast_GLOBAL18.003 s [18.003 s, 18.003 s]3.041 s (20.3%)
profiling15.502 s [15.502 s, 15.502 s]540.0 ms (3.6%)
tracing15.045 s [15.045 s, 15.045 s]83.0 ms (0.6%)
Execution time for tomcat
gantt
title tomcat - execution time [CI 0.99] : candidate=1.50.0-SNAPSHOT~91445aea2f, baseline=1.50.0-SNAPSHOT~f494c33b01
dateFormat X
axisFormat %s
section baseline
no_agent (1.483 ms) : 1471, 1495
. : milestone, 1483,
appsec (2.418 ms) : 2368, 2467
. : milestone, 2418,
iast (2.202 ms) : 2140, 2264
. : milestone, 2202,
iast_GLOBAL (2.233 ms) : 2171, 2295
. : milestone, 2233,
profiling (2.05 ms) : 2000, 2100
. : milestone, 2050,
tracing (2.033 ms) : 1984, 2081
. : milestone, 2033,
section candidate
no_agent (1.478 ms) : 1467, 1490
. : milestone, 1478,
appsec (2.418 ms) : 2369, 2468
. : milestone, 2418,
iast (2.204 ms) : 2142, 2266
. : milestone, 2204,
iast_GLOBAL (2.248 ms) : 2185, 2311
. : milestone, 2248,
profiling (2.041 ms) : 1992, 2090
. : milestone, 2041,
tracing (2.028 ms) : 1980, 2076
. : milestone, 2028,
Loading
  • baseline results
VariantExecution Time [CI 0.99]Δ no_agent
no_agent1.483 ms [1.471 ms, 1.495 ms]-
appsec2.418 ms [2.368 ms, 2.467 ms]934.494 µs (63.0%)
iast2.202 ms [2.14 ms, 2.264 ms]718.712 µs (48.5%)
iast_GLOBAL2.233 ms [2.171 ms, 2.295 ms]749.783 µs (50.6%)
profiling2.05 ms [2.0 ms, 2.1 ms]567.034 µs (38.2%)
tracing2.033 ms [1.984 ms, 2.081 ms]549.694 µs (37.1%)
  • candidate results
VariantExecution Time [CI 0.99]Δ no_agent
no_agent1.478 ms [1.467 ms, 1.49 ms]-
appsec2.418 ms [2.369 ms, 2.468 ms]940.276 µs (63.6%)
iast2.204 ms [2.142 ms, 2.266 ms]725.574 µs (49.1%)
iast_GLOBAL2.248 ms [2.185 ms, 2.311 ms]770.175 µs (52.1%)
profiling2.041 ms [1.992 ms, 2.09 ms]562.725 µs (38.1%)
tracing2.028 ms [1.98 ms, 2.076 ms]549.922 µs (37.2%)

@mccullsmcculls changed the title WIP: Rework Kotlin coroutines instrumentation around coroutine contextRework Kotlin coroutines instrumentation around coroutine contextMay 7, 2025
@mcculls
mccullsforce-pushed the mcculls/rework-kotlin-instrumentation branch 4 times, most recently from a77d8bd to 06b989fCompareMay 7, 2025 15:04
@mccullsmcculls removed the tag: do not merge Do not merge changes label May 7, 2025
@mcculls
mcculls marked this pull request as ready for review May 7, 2025 16:13
@mcculls
mcculls requested review from a team as code ownersMay 7, 2025 16:13
@mccullsmcculls added tag: no release notes Changes to exclude from release notes and removed tag: no release notes Changes to exclude from release notes labels May 7, 2025
@mcculls
mccullsforce-pushed the mcculls/rework-kotlin-instrumentation branch 3 times, most recently from 48b5305 to 37ba1f6CompareMay 11, 2025 18:23
As an added benefit, this approach does not require field injection

@amarzialiamarziali left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great contribution. Much cleaner than before. Thanks also for the detailed description

@PerfectSlayerPerfectSlayer left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice improvement! 👍

@mcculls
mcculls merged commit 4738946 into masterMay 12, 2025
@mcculls
mcculls deleted the mcculls/rework-kotlin-instrumentation branch May 12, 2025 09:29
@github-actionsgithub-actionsBot added this to the 1.50.0 milestone May 12, 2025
svc-squareup-copybara pushed a commit to cashapp/misk that referenced this pull request Jun 20, 2025
| Package | Type | Package file | Manager | Update | Change |
|---|---|---|---|---|---|
| [com.datadoghq:dd-trace-api](https://github.com/datadog/dd-trace-java)
| dependencies | misk/gradle/libs.versions.toml | gradle | minor |
`1.49.0` -> `1.50.0` |
---
### Release Notes
<details>
<summary>datadog/dd-trace-java (com.datadoghq:dd-trace-api)</summary>
###
[`v1.50.0`](https://github.com/DataDog/dd-trace-java/releases/tag/v1.50.0):
1.50.0
### Deprecation Notice
> \[!NOTE]
> `DD_RUNTIME_ID_ENABLED` has been deprecated and will be removed in
future releases. Please use `DD_RUNTIME_METRICS_RUNTIME_ID_ENABLED`
instead.
### Components
#### Application Security Management (WAF)
- 🐛 Add String length truncation limit to ObjectIntrospector and
update truncation metrics
([#&#8203;8825](DataDog/dd-trace-java#8825) -
[@&#8203;jandro996](https://github.com/jandro996))
- 🐛 Adapt standalone ASM to support API Security
([#&#8203;8804](DataDog/dd-trace-java#8804) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Add appsec.waf.input\_truncated metric
([#&#8203;8791](DataDog/dd-trace-java#8791) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Extended appsec request body collection
([#&#8203;8748](DataDog/dd-trace-java#8748) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Extended appsec request/response headers collection
([#&#8203;8724](DataDog/dd-trace-java#8724) -
[@&#8203;jandro996](https://github.com/jandro996))
#### Build & Tooling
- ✨ Add artifacts to public s3 bucket
([#&#8203;8947](DataDog/dd-trace-java#8947) -
[@&#8203;randomanderson](https://github.com/randomanderson))
#### Continuous Integration Visibility
- ✨ Improve PR information building
([#&#8203;8908](DataDog/dd-trace-java#8908) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Truncate span stack traces when Test Optimization is
enabled
([#&#8203;8903](DataDog/dd-trace-java#8903) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🐛 Ensure auto-detected service name is the same for every process
in the same build
([#&#8203;8902](DataDog/dd-trace-java#8902) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🐛 Use tag as fallback in api requests if no branch is available
([#&#8203;8876](DataDog/dd-trace-java#8876) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Add support for JUnit 5.13-RC1
([#&#8203;8865](DataDog/dd-trace-java#8865),
[#&#8203;8871](DataDog/dd-trace-java#8871) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Implement attempt to fix v3 and v4 and bump capability
version
([#&#8203;8824](DataDog/dd-trace-java#8824) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- 🧹 Align retry logic for all test framework instrumentations
([#&#8203;8803](DataDog/dd-trace-java#8803) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- 🐛 Always build ci workspace without trailing separator
([#&#8203;8788](DataDog/dd-trace-java#8788) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Add commit discrepancies telemetry when building repository
git information
([#&#8203;8763](DataDog/dd-trace-java#8763) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
#### Data Streams Monitoring
- 💡 Surface process tags in dsm payloads and use them for base hash
calculation
([#&#8203;8836](DataDog/dd-trace-java#8836) -
[@&#8203;amarziali](https://github.com/amarziali))
#### Dynamic Instrumentation
- ✨ Optimized allocations for collection filter functions
([#&#8203;8896](DataDog/dd-trace-java#8896) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Fix SymDB upload size check
([#&#8203;8887](DataDog/dd-trace-java#8887) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Add support for Set in filter function
([#&#8203;8873](DataDog/dd-trace-java#8873) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Add support for isDefined in log template
([#&#8203;8859](DataDog/dd-trace-java#8859) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Fix Max captured frames for Exception Replay
([#&#8203;8856](DataDog/dd-trace-java#8856) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Remove static inherited fields collection
([#&#8203;8832](DataDog/dd-trace-java#8832) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 💡 Add process tags to dynamic instrumentation intake payload
([#&#8203;8779](DataDog/dd-trace-java#8779) -
[@&#8203;amarziali](https://github.com/amarziali))
#### GraalVM native-image
- ✨ Add support for GraalVM Native GC metrics
([#&#8203;8913](DataDog/dd-trace-java#8913) -
[@&#8203;ygree](https://github.com/ygree))
- ✨ Add JMXFetch support for GraalVM Native
([#&#8203;8569](DataDog/dd-trace-java#8569) -
[@&#8203;ygree](https://github.com/ygree))
#### JMX fetch
- ✨ Add support for GraalVM Native GC metrics
([#&#8203;8913](DataDog/dd-trace-java#8913) -
[@&#8203;ygree](https://github.com/ygree))
#### Library Injection
- ✨ Deny oracle db jvm based tools
([#&#8203;8909](DataDog/dd-trace-java#8909) -
[@&#8203;bric3](https://github.com/bric3))
#### OpenTracing
- 🐛 Fix OT packaging for exception replay
([#&#8203;8912](DataDog/dd-trace-java#8912) -
[@&#8203;jpbempel](https://github.com/jpbempel))
#### Profiling
- ✨ Bump ddprof to 1.27.0
([#&#8203;8893](DataDog/dd-trace-java#8893) -
[@&#8203;jbachorik](https://github.com/jbachorik))
- Properly handle the adaptive sampling interval overflow by
[@&#8203;jbachorik](https://github.com/jbachorik) in
DataDog/java-profiler#213
- Fix [#&#8203;200](DataDog/dd-trace-java#200)
Crash related to aligned\_alloc and free in context by
[@&#8203;yanglong1010](https://github.com/yanglong1010) in
DataDog/java-profiler#208
- Explicitly initialize empty context page by
[@&#8203;jbachorik](https://github.com/jbachorik) in
DataDog/java-profiler#210
- Re-connect crash recursion protection with VM stackwalker by
[@&#8203;jbachorik](https://github.com/jbachorik) in
DataDog/java-profiler#214
- ✨ Enable ZSTD compression for profiling
([#&#8203;8862](DataDog/dd-trace-java#8862) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- ✨ Extend JPS re-implementation to J9 family
([#&#8203;8813](DataDog/dd-trace-java#8813) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- 💡 Collect process tags for profiling upload requests
([#&#8203;8780](DataDog/dd-trace-java#8780) -
[@&#8203;amarziali](https://github.com/amarziali))
#### Telemetry
- 💡 Surface process tags on telemetry payloads
([#&#8203;8837](DataDog/dd-trace-java#8837) -
[@&#8203;amarziali](https://github.com/amarziali))
#### Trace context propagation
- ✨ Migrating all HttpClient Instrumentations to Inject Full
Context
([#&#8203;8826](DataDog/dd-trace-java#8826) -
[@&#8203;mhlidd](https://github.com/mhlidd))
- ✨ Migrating all HttpServer Instrumentations to Extract full
Context
([#&#8203;8820](DataDog/dd-trace-java#8820) -
[@&#8203;mhlidd](https://github.com/mhlidd))
- ✨ Add context API support OTel propagators
([#&#8203;8770](DataDog/dd-trace-java#8770) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
#### Tracer core
- ✨⚡ Skip JAXB generated classes classloader
([#&#8203;9003](DataDog/dd-trace-java#9003) -
[@&#8203;bric3](https://github.com/bric3))
- ✨ Add DD\_RUNTIME\_METRICS\_RUNTIME\_ID\_ENABLED alias for
runtime id generation
([#&#8203;8981](DataDog/dd-trace-java#8981) -
[@&#8203;amarziali](https://github.com/amarziali))
- 🐛 Use resolved address for peer.hostname when available without
hitting the cache
([#&#8203;8915](DataDog/dd-trace-java#8915) -
[@&#8203;amarziali](https://github.com/amarziali))
- 💡 Surface server name process tag for tomcat
([#&#8203;8894](DataDog/dd-trace-java#8894) -
[@&#8203;amarziali](https://github.com/amarziali))
- 💡 Surface websphere cell and server name on process tags
([#&#8203;8880](DataDog/dd-trace-java#8880) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Added special lightweight pre-main class that skips
installation on incompatible JVMs.
([#&#8203;8855](DataDog/dd-trace-java#8855) -
[@&#8203;AlexeyKuznetsov-DD](https://github.com/AlexeyKuznetsov-DD))
- 💡 Add entrypoint type to process tags
([#&#8203;8839](DataDog/dd-trace-java#8839) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Extend JPS re-implementation to J9 family
([#&#8203;8813](DataDog/dd-trace-java#8813) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- ✨ Notify listeners when the scope top changes after switching
scope stacks
([#&#8203;8797](DataDog/dd-trace-java#8797) -
[@&#8203;mcculls](https://github.com/mcculls))
- ✨ Read hsperfdata for Java PIDs if jvmstat is unavailable
([#&#8203;8792](DataDog/dd-trace-java#8792) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- 🐛 Turn JDK socket support on by default
([#&#8203;8752](DataDog/dd-trace-java#8752) -
[@&#8203;sarahchen6](https://github.com/sarahchen6))
- ✨ Simplify context propagation
([#&#8203;8719](DataDog/dd-trace-java#8719) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
- ✨ Add JSON parsing support
([#&#8203;8579](DataDog/dd-trace-java#8579) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
#### Tracer internal logging
- ✨ Fix printing format of span identifiers
([#&#8203;8897](DataDog/dd-trace-java#8897) -
[@&#8203;vandonr](https://github.com/vandonr))
#### Tracer public API
- 💡 Track the source of installation
([#&#8203;8956](DataDog/dd-trace-java#8956) -
[@&#8203;mabdinur](https://github.com/mabdinur))
- ✨ Enforce size limit on application\_monitoring.yaml files
([#&#8203;8789](DataDog/dd-trace-java#8789) -
[@&#8203;mtoffl01](https://github.com/mtoffl01))
- ✨ Enabling baggage cache to support limits and non-ascii
characters
([#&#8203;8713](DataDog/dd-trace-java#8713) -
[@&#8203;mhlidd](https://github.com/mhlidd))
### Instrumentations
#### AWS Lambda instrumentation
- ✨ Pass Lambda Request ID to Extension
([#&#8203;8814](DataDog/dd-trace-java#8814) -
[@&#8203;nhulston](https://github.com/nhulston))
#### Core Java language instrumentation
- ✨ Ensure ClassloadingInstrumentation is always applied even
with `DD_TRACE_ENABLED=false`
([#&#8203;8863](DataDog/dd-trace-java#8863) -
[@&#8203;mcculls](https://github.com/mcculls))
#### Eclipse Vert.x instrumentation
- 🐛 Do not override route with / in vertx instrumentation
([#&#8203;8881](DataDog/dd-trace-java#8881) -
[@&#8203;vandonr](https://github.com/vandonr))
#### IBM Liberty
- 🐛 Fix error mark on http status for IBM liberty
([#&#8203;8822](DataDog/dd-trace-java#8822) -
[@&#8203;amarziali](https://github.com/amarziali))
#### JDBC instrumentation
- 🐛 Do not prepend DBM <> APM trace comment in SQLCommenter if there
is a pg plan hint
([#&#8203;8864](DataDog/dd-trace-java#8864) -
[@&#8203;edengorevoy](https://github.com/edengorevoy))
#### JMS instrumentation
- ✨ Add jms as an extra integration name where there is JMS
involved
([#&#8203;8933](DataDog/dd-trace-java#8933) -
[@&#8203;vandonr](https://github.com/vandonr))
#### Kotlin instrumentation
- ✨ Enable kotlin\_coroutine integration by default
([#&#8203;8848](DataDog/dd-trace-java#8848) -
[@&#8203;mcculls](https://github.com/mcculls))
- 🧹 Rework Kotlin coroutines instrumentation around coroutine
context
([#&#8203;8774](DataDog/dd-trace-java#8774) -
[@&#8203;mcculls](https://github.com/mcculls))
#### OpenTelemetry instrumentation
- 🐛 Support WithSpan inheritContext attribute
([#&#8203;8858](DataDog/dd-trace-java#8858) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Add context API support OTel propagators
([#&#8203;8770](DataDog/dd-trace-java#8770) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
#### Play Framework instrumentation
- 🐛 Fix the Play Framework's span resource name priority so that the
client JAX-RS 404 cannot override it
([#&#8203;8591](DataDog/dd-trace-java#8591) -
[@&#8203;ygree](https://github.com/ygree))
#### Quarkus Instrumentation
- 🐛 Ignore quarkus jaxrs stubs and cdi wrapper proxies
([#&#8203;8891](DataDog/dd-trace-java#8891) -
[@&#8203;amarziali](https://github.com/amarziali))
#### ServiceTalk
- ✨ Improve ServiceTalk Captured Context API Instrumentation
for v0.42.56+
([#&#8203;8821](DataDog/dd-trace-java#8821) -
[@&#8203;ygree](https://github.com/ygree))
#### Spring instrumentation
- ✨ Supporting Baggage for Instrumentations used in Weblog
Tests
([#&#8203;8773](DataDog/dd-trace-java#8773) -
[@&#8203;mhlidd](https://github.com/mhlidd))
#### WebSocket Instrumentation
- 💡 Trace websocket for spring webflux reactive handlers
([#&#8203;8831](DataDog/dd-trace-java#8831) -
[@&#8203;amarziali](https://github.com/amarziali))
- 💡:test\_tube: WebSocket support for Netty
([#&#8203;8632](DataDog/dd-trace-java#8632) -
[@&#8203;ValentinZakharov](https://github.com/ValentinZakharov))
#### Zio Instrumentation
- 🧹 Cleanup Zio fiber instrumentation to avoid repeated activation
of continuation
([#&#8203;8798](DataDog/dd-trace-java#8798) -
[@&#8203;mcculls](https://github.com/mcculls))
</details>
---
### Configuration
📅 **Schedule**: Branch creation - "after 6pm every weekday,before 2am
every weekday" in timezone Australia/Melbourne, Automerge - At any time
(no schedule defined).
🚦 **Automerge**: Enabled.
♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR has been generated by [Renovate
Bot](https://github.com/renovatebot/renovate).
GitOrigin-RevId: 9207366cdb6a1bd098082305d354a0a3c4622d7a
@andreimatei

Copy link
Copy Markdown
Contributor

Did this patch fix #5917 ?

@mcculls

mcculls commented Mar 25, 2026

Copy link
Copy Markdown
ContributorAuthor

@andreimatei Kotlin coroutines annotated with @Trace that implement a blocking operation such as delay currently produce two spans - one for the block of code before the blocking operation, and another for the block of code after the operation.

This is because the Kotlin compiler adjusts the coroutine method bytecode to add a switch right at the top of the method, so it can jump directly to each block of code. The first time the method is called it jumps to the first block, and exits when it reaches the blocking operation. Once that blocking operation is complete then it calls the method again with a special argument which tells it to jump to the second block.

From a JVM (and tracer) perspective this means the @Trace’d method is called twice, with the scope being closed in-between the two calls (so two spans and therefore two traces if there's no enclosing trace.)

To fix this properly we need to exclude these particular Kotlin coroutine methods from the usual @Trace advice and instead introduce special handling - this work is in addition to this lower-level fix

eizus pushed a commit to cdrxyz/misk that referenced this pull request Jul 18, 2026
| Package | Type | Package file | Manager | Update | Change |
|---|---|---|---|---|---|
| [com.datadoghq:dd-trace-api](https://github.com/datadog/dd-trace-java)
| dependencies | misk/gradle/libs.versions.toml | gradle | minor |
`1.49.0` -> `1.50.0` |
---
### Release Notes
<details>
<summary>datadog/dd-trace-java (com.datadoghq:dd-trace-api)</summary>
###
[`v1.50.0`](https://github.com/DataDog/dd-trace-java/releases/tag/v1.50.0):
1.50.0
### Deprecation Notice
> \[!NOTE]
> `DD_RUNTIME_ID_ENABLED` has been deprecated and will be removed in
future releases. Please use `DD_RUNTIME_METRICS_RUNTIME_ID_ENABLED`
instead.
### Components
#### Application Security Management (WAF)
- 🐛 Add String length truncation limit to ObjectIntrospector and
update truncation metrics
([#&#8203;8825](DataDog/dd-trace-java#8825) -
[@&#8203;jandro996](https://github.com/jandro996))
- 🐛 Adapt standalone ASM to support API Security
([#&#8203;8804](DataDog/dd-trace-java#8804) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Add appsec.waf.input\_truncated metric
([#&#8203;8791](DataDog/dd-trace-java#8791) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Extended appsec request body collection
([#&#8203;8748](DataDog/dd-trace-java#8748) -
[@&#8203;jandro996](https://github.com/jandro996))
- ✨ Extended appsec request/response headers collection
([#&#8203;8724](DataDog/dd-trace-java#8724) -
[@&#8203;jandro996](https://github.com/jandro996))
#### Build & Tooling
- ✨ Add artifacts to public s3 bucket
([#&#8203;8947](DataDog/dd-trace-java#8947) -
[@&#8203;randomanderson](https://github.com/randomanderson))
#### Continuous Integration Visibility
- ✨ Improve PR information building
([#&#8203;8908](DataDog/dd-trace-java#8908) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Truncate span stack traces when Test Optimization is
enabled
([#&#8203;8903](DataDog/dd-trace-java#8903) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🐛 Ensure auto-detected service name is the same for every process
in the same build
([#&#8203;8902](DataDog/dd-trace-java#8902) -
[@&#8203;nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog))
- 🐛 Use tag as fallback in api requests if no branch is available
([#&#8203;8876](DataDog/dd-trace-java#8876) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Add support for JUnit 5.13-RC1
([#&#8203;8865](DataDog/dd-trace-java#8865),
[#&#8203;8871](DataDog/dd-trace-java#8871) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Implement attempt to fix v3 and v4 and bump capability
version
([#&#8203;8824](DataDog/dd-trace-java#8824) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- 🧹 Align retry logic for all test framework instrumentations
([#&#8203;8803](DataDog/dd-trace-java#8803) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- 🐛 Always build ci workspace without trailing separator
([#&#8203;8788](DataDog/dd-trace-java#8788) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
- ✨ Add commit discrepancies telemetry when building repository
git information
([#&#8203;8763](DataDog/dd-trace-java#8763) -
[@&#8203;daniel-mohedano](https://github.com/daniel-mohedano))
#### Data Streams Monitoring
- 💡 Surface process tags in dsm payloads and use them for base hash
calculation
([#&#8203;8836](DataDog/dd-trace-java#8836) -
[@&#8203;amarziali](https://github.com/amarziali))
#### Dynamic Instrumentation
- ✨ Optimized allocations for collection filter functions
([#&#8203;8896](DataDog/dd-trace-java#8896) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Fix SymDB upload size check
([#&#8203;8887](DataDog/dd-trace-java#8887) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Add support for Set in filter function
([#&#8203;8873](DataDog/dd-trace-java#8873) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Add support for isDefined in log template
([#&#8203;8859](DataDog/dd-trace-java#8859) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Fix Max captured frames for Exception Replay
([#&#8203;8856](DataDog/dd-trace-java#8856) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 🐛 Remove static inherited fields collection
([#&#8203;8832](DataDog/dd-trace-java#8832) -
[@&#8203;jpbempel](https://github.com/jpbempel))
- 💡 Add process tags to dynamic instrumentation intake payload
([#&#8203;8779](DataDog/dd-trace-java#8779) -
[@&#8203;amarziali](https://github.com/amarziali))
#### GraalVM native-image
- ✨ Add support for GraalVM Native GC metrics
([#&#8203;8913](DataDog/dd-trace-java#8913) -
[@&#8203;ygree](https://github.com/ygree))
- ✨ Add JMXFetch support for GraalVM Native
([#&#8203;8569](DataDog/dd-trace-java#8569) -
[@&#8203;ygree](https://github.com/ygree))
#### JMX fetch
- ✨ Add support for GraalVM Native GC metrics
([#&#8203;8913](DataDog/dd-trace-java#8913) -
[@&#8203;ygree](https://github.com/ygree))
#### Library Injection
- ✨ Deny oracle db jvm based tools
([#&#8203;8909](DataDog/dd-trace-java#8909) -
[@&#8203;bric3](https://github.com/bric3))
#### OpenTracing
- 🐛 Fix OT packaging for exception replay
([#&#8203;8912](DataDog/dd-trace-java#8912) -
[@&#8203;jpbempel](https://github.com/jpbempel))
#### Profiling
- ✨ Bump ddprof to 1.27.0
([#&#8203;8893](DataDog/dd-trace-java#8893) -
[@&#8203;jbachorik](https://github.com/jbachorik))
- Properly handle the adaptive sampling interval overflow by
[@&#8203;jbachorik](https://github.com/jbachorik) in
DataDog/java-profiler#213
- Fix [#&#8203;200](DataDog/dd-trace-java#200)
Crash related to aligned\_alloc and free in context by
[@&#8203;yanglong1010](https://github.com/yanglong1010) in
DataDog/java-profiler#208
- Explicitly initialize empty context page by
[@&#8203;jbachorik](https://github.com/jbachorik) in
DataDog/java-profiler#210
- Re-connect crash recursion protection with VM stackwalker by
[@&#8203;jbachorik](https://github.com/jbachorik) in
DataDog/java-profiler#214
- ✨ Enable ZSTD compression for profiling
([#&#8203;8862](DataDog/dd-trace-java#8862) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- ✨ Extend JPS re-implementation to J9 family
([#&#8203;8813](DataDog/dd-trace-java#8813) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- 💡 Collect process tags for profiling upload requests
([#&#8203;8780](DataDog/dd-trace-java#8780) -
[@&#8203;amarziali](https://github.com/amarziali))
#### Telemetry
- 💡 Surface process tags on telemetry payloads
([#&#8203;8837](DataDog/dd-trace-java#8837) -
[@&#8203;amarziali](https://github.com/amarziali))
#### Trace context propagation
- ✨ Migrating all HttpClient Instrumentations to Inject Full
Context
([#&#8203;8826](DataDog/dd-trace-java#8826) -
[@&#8203;mhlidd](https://github.com/mhlidd))
- ✨ Migrating all HttpServer Instrumentations to Extract full
Context
([#&#8203;8820](DataDog/dd-trace-java#8820) -
[@&#8203;mhlidd](https://github.com/mhlidd))
- ✨ Add context API support OTel propagators
([#&#8203;8770](DataDog/dd-trace-java#8770) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
#### Tracer core
- ✨⚡ Skip JAXB generated classes classloader
([#&#8203;9003](DataDog/dd-trace-java#9003) -
[@&#8203;bric3](https://github.com/bric3))
- ✨ Add DD\_RUNTIME\_METRICS\_RUNTIME\_ID\_ENABLED alias for
runtime id generation
([#&#8203;8981](DataDog/dd-trace-java#8981) -
[@&#8203;amarziali](https://github.com/amarziali))
- 🐛 Use resolved address for peer.hostname when available without
hitting the cache
([#&#8203;8915](DataDog/dd-trace-java#8915) -
[@&#8203;amarziali](https://github.com/amarziali))
- 💡 Surface server name process tag for tomcat
([#&#8203;8894](DataDog/dd-trace-java#8894) -
[@&#8203;amarziali](https://github.com/amarziali))
- 💡 Surface websphere cell and server name on process tags
([#&#8203;8880](DataDog/dd-trace-java#8880) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Added special lightweight pre-main class that skips
installation on incompatible JVMs.
([#&#8203;8855](DataDog/dd-trace-java#8855) -
[@&#8203;AlexeyKuznetsov-DD](https://github.com/AlexeyKuznetsov-DD))
- 💡 Add entrypoint type to process tags
([#&#8203;8839](DataDog/dd-trace-java#8839) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Extend JPS re-implementation to J9 family
([#&#8203;8813](DataDog/dd-trace-java#8813) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- ✨ Notify listeners when the scope top changes after switching
scope stacks
([#&#8203;8797](DataDog/dd-trace-java#8797) -
[@&#8203;mcculls](https://github.com/mcculls))
- ✨ Read hsperfdata for Java PIDs if jvmstat is unavailable
([#&#8203;8792](DataDog/dd-trace-java#8792) -
[@&#8203;MattAlp](https://github.com/MattAlp))
- 🐛 Turn JDK socket support on by default
([#&#8203;8752](DataDog/dd-trace-java#8752) -
[@&#8203;sarahchen6](https://github.com/sarahchen6))
- ✨ Simplify context propagation
([#&#8203;8719](DataDog/dd-trace-java#8719) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
- ✨ Add JSON parsing support
([#&#8203;8579](DataDog/dd-trace-java#8579) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
#### Tracer internal logging
- ✨ Fix printing format of span identifiers
([#&#8203;8897](DataDog/dd-trace-java#8897) -
[@&#8203;vandonr](https://github.com/vandonr))
#### Tracer public API
- 💡 Track the source of installation
([#&#8203;8956](DataDog/dd-trace-java#8956) -
[@&#8203;mabdinur](https://github.com/mabdinur))
- ✨ Enforce size limit on application\_monitoring.yaml files
([#&#8203;8789](DataDog/dd-trace-java#8789) -
[@&#8203;mtoffl01](https://github.com/mtoffl01))
- ✨ Enabling baggage cache to support limits and non-ascii
characters
([#&#8203;8713](DataDog/dd-trace-java#8713) -
[@&#8203;mhlidd](https://github.com/mhlidd))
### Instrumentations
#### AWS Lambda instrumentation
- ✨ Pass Lambda Request ID to Extension
([#&#8203;8814](DataDog/dd-trace-java#8814) -
[@&#8203;nhulston](https://github.com/nhulston))
#### Core Java language instrumentation
- ✨ Ensure ClassloadingInstrumentation is always applied even
with `DD_TRACE_ENABLED=false`
([#&#8203;8863](DataDog/dd-trace-java#8863) -
[@&#8203;mcculls](https://github.com/mcculls))
#### Eclipse Vert.x instrumentation
- 🐛 Do not override route with / in vertx instrumentation
([#&#8203;8881](DataDog/dd-trace-java#8881) -
[@&#8203;vandonr](https://github.com/vandonr))
#### IBM Liberty
- 🐛 Fix error mark on http status for IBM liberty
([#&#8203;8822](DataDog/dd-trace-java#8822) -
[@&#8203;amarziali](https://github.com/amarziali))
#### JDBC instrumentation
- 🐛 Do not prepend DBM <> APM trace comment in SQLCommenter if there
is a pg plan hint
([#&#8203;8864](DataDog/dd-trace-java#8864) -
[@&#8203;edengorevoy](https://github.com/edengorevoy))
#### JMS instrumentation
- ✨ Add jms as an extra integration name where there is JMS
involved
([#&#8203;8933](DataDog/dd-trace-java#8933) -
[@&#8203;vandonr](https://github.com/vandonr))
#### Kotlin instrumentation
- ✨ Enable kotlin\_coroutine integration by default
([#&#8203;8848](DataDog/dd-trace-java#8848) -
[@&#8203;mcculls](https://github.com/mcculls))
- 🧹 Rework Kotlin coroutines instrumentation around coroutine
context
([#&#8203;8774](DataDog/dd-trace-java#8774) -
[@&#8203;mcculls](https://github.com/mcculls))
#### OpenTelemetry instrumentation
- 🐛 Support WithSpan inheritContext attribute
([#&#8203;8858](DataDog/dd-trace-java#8858) -
[@&#8203;amarziali](https://github.com/amarziali))
- ✨ Add context API support OTel propagators
([#&#8203;8770](DataDog/dd-trace-java#8770) -
[@&#8203;PerfectSlayer](https://github.com/PerfectSlayer))
#### Play Framework instrumentation
- 🐛 Fix the Play Framework's span resource name priority so that the
client JAX-RS 404 cannot override it
([#&#8203;8591](DataDog/dd-trace-java#8591) -
[@&#8203;ygree](https://github.com/ygree))
#### Quarkus Instrumentation
- 🐛 Ignore quarkus jaxrs stubs and cdi wrapper proxies
([#&#8203;8891](DataDog/dd-trace-java#8891) -
[@&#8203;amarziali](https://github.com/amarziali))
#### ServiceTalk
- ✨ Improve ServiceTalk Captured Context API Instrumentation
for v0.42.56+
([#&#8203;8821](DataDog/dd-trace-java#8821) -
[@&#8203;ygree](https://github.com/ygree))
#### Spring instrumentation
- ✨ Supporting Baggage for Instrumentations used in Weblog
Tests
([#&#8203;8773](DataDog/dd-trace-java#8773) -
[@&#8203;mhlidd](https://github.com/mhlidd))
#### WebSocket Instrumentation
- 💡 Trace websocket for spring webflux reactive handlers
([#&#8203;8831](DataDog/dd-trace-java#8831) -
[@&#8203;amarziali](https://github.com/amarziali))
- 💡:test\_tube: WebSocket support for Netty
([#&#8203;8632](DataDog/dd-trace-java#8632) -
[@&#8203;ValentinZakharov](https://github.com/ValentinZakharov))
#### Zio Instrumentation
- 🧹 Cleanup Zio fiber instrumentation to avoid repeated activation
of continuation
([#&#8203;8798](DataDog/dd-trace-java#8798) -
[@&#8203;mcculls](https://github.com/mcculls))
</details>
---
### Configuration
📅 **Schedule**: Branch creation - "after 6pm every weekday,before 2am
every weekday" in timezone Australia/Melbourne, Automerge - At any time
(no schedule defined).
🚦 **Automerge**: Enabled.
♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR has been generated by [Renovate
Bot](https://github.com/renovatebot/renovate).
GitOrigin-RevId: 9207366cdb6a1bd098082305d354a0a3c4622d7a
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

inst: kotlinKotlin instrumentationtype: refactoring

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@mcculls@andreimatei@PerfectSlayer@amarziali