-
Notifications
You must be signed in to change notification settings - Fork 300
Take defensive copy of parent scope stack when closing nested coroutines #8749
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
Conversation
c83ce0e
to
3599902
Compare
if (contextItem != null) { | ||
ScopeState currentThreadScopeState = null; | ||
if (parent != null) { | ||
final ScopeStateCoroutineContextItem parentItem = contextItemPerCoroutine.get(parent); | ||
if (parentItem != null) { | ||
currentThreadScopeState = parentItem.getScopeState(); | ||
// take defensive copy of parent scope stack | ||
currentThreadScopeState = parentItem.copyScopeState(); |
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.
copying looks pretty costly however it should not be an issue given that it's called only when the coroutine reach its termination state
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.
e224cd2 should reduce this to only copying when it's essential
Note this whole area of code will soon get refactored/replaced - so this is only needed in the short-term
BenchmarksStartupParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 63 metrics, 8 unstable metrics. Startup time reports for petclinicgantt
title petclinic - global startup overhead: candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.007 s) : 0, 1006997
Total [baseline] (10.566 s) : 0, 10566299
Agent [candidate] (1.015 s) : 0, 1014838
Total [candidate] (10.596 s) : 0, 10595559
section appsec
Agent [baseline] (1.152 s) : 0, 1152100
Total [baseline] (10.66 s) : 0, 10660019
Agent [candidate] (1.15 s) : 0, 1149939
Total [candidate] (10.68 s) : 0, 10680282
section iast
Agent [baseline] (1.137 s) : 0, 1137003
Total [baseline] (10.775 s) : 0, 10774724
Agent [candidate] (1.136 s) : 0, 1135852
Total [candidate] (10.821 s) : 0, 10821403
section profiling
Agent [baseline] (1.256 s) : 0, 1255733
Total [baseline] (10.797 s) : 0, 10797261
Agent [candidate] (1.263 s) : 0, 1262565
Total [candidate] (10.778 s) : 0, 10777846
gantt
title petclinic - break down per module: candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (670.908 ms) : 0, 670908
BytebuddyAgent [candidate] (676.581 ms) : 0, 676581
GlobalTracer [baseline] (240.446 ms) : 0, 240446
GlobalTracer [candidate] (241.683 ms) : 0, 241683
AppSec [baseline] (54.688 ms) : 0, 54688
AppSec [candidate] (55.086 ms) : 0, 55086
Debugger [baseline] (6.152 ms) : 0, 6152
Debugger [candidate] (6.914 ms) : 0, 6914
Remote Config [baseline] (697.01 µs) : 0, 697
Remote Config [candidate] (704.921 µs) : 0, 705
Telemetry [baseline] (10.675 ms) : 0, 10675
Telemetry [candidate] (9.978 ms) : 0, 9978
section appsec
BytebuddyAgent [baseline] (690.838 ms) : 0, 690838
BytebuddyAgent [candidate] (689.268 ms) : 0, 689268
GlobalTracer [baseline] (237.018 ms) : 0, 237018
GlobalTracer [candidate] (236.778 ms) : 0, 236778
AppSec [baseline] (175.64 ms) : 0, 175640
AppSec [candidate] (174.493 ms) : 0, 174493
Debugger [baseline] (5.837 ms) : 0, 5837
Debugger [candidate] (5.849 ms) : 0, 5849
Remote Config [baseline] (635.734 µs) : 0, 636
Remote Config [candidate] (631.143 µs) : 0, 631
Telemetry [baseline] (7.751 ms) : 0, 7751
Telemetry [candidate] (8.558 ms) : 0, 8558
IAST [baseline] (21.743 ms) : 0, 21743
IAST [candidate] (21.793 ms) : 0, 21793
section iast
BytebuddyAgent [baseline] (789.916 ms) : 0, 789916
BytebuddyAgent [candidate] (788.976 ms) : 0, 788976
GlobalTracer [baseline] (230.086 ms) : 0, 230086
GlobalTracer [candidate] (229.777 ms) : 0, 229777
AppSec [baseline] (56.627 ms) : 0, 56627
AppSec [candidate] (56.553 ms) : 0, 56553
Debugger [baseline] (5.859 ms) : 0, 5859
Debugger [candidate] (5.906 ms) : 0, 5906
Remote Config [baseline] (598.203 µs) : 0, 598
Remote Config [candidate] (577.243 µs) : 0, 577
Telemetry [baseline] (7.837 ms) : 0, 7837
Telemetry [candidate] (7.903 ms) : 0, 7903
IAST [baseline] (22.673 ms) : 0, 22673
IAST [candidate] (22.8 ms) : 0, 22800
section profiling
BytebuddyAgent [baseline] (662.919 ms) : 0, 662919
BytebuddyAgent [candidate] (667.888 ms) : 0, 667888
GlobalTracer [baseline] (376.293 ms) : 0, 376293
GlobalTracer [candidate] (378.538 ms) : 0, 378538
AppSec [baseline] (54.287 ms) : 0, 54287
AppSec [candidate] (53.652 ms) : 0, 53652
Debugger [baseline] (6.129 ms) : 0, 6129
Debugger [candidate] (6.178 ms) : 0, 6178
Remote Config [baseline] (664.865 µs) : 0, 665
Remote Config [candidate] (651.481 µs) : 0, 651
Telemetry [baseline] (8.217 ms) : 0, 8217
Telemetry [candidate] (8.268 ms) : 0, 8268
ProfilingAgent [baseline] (96.996 ms) : 0, 96996
ProfilingAgent [candidate] (96.856 ms) : 0, 96856
Profiling [baseline] (97.019 ms) : 0, 97019
Profiling [candidate] (96.88 ms) : 0, 96880
Startup time reports for insecure-bankgantt
title insecure-bank - global startup overhead: candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section tracing
Agent [baseline] (1.009 s) : 0, 1009110
Total [baseline] (8.629 s) : 0, 8629479
Agent [candidate] (1.011 s) : 0, 1010592
Total [candidate] (8.649 s) : 0, 8649051
section iast
Agent [baseline] (1.135 s) : 0, 1135144
Total [baseline] (9.206 s) : 0, 9206477
Agent [candidate] (1.142 s) : 0, 1142198
Total [candidate] (9.221 s) : 0, 9220826
section iast_HARDCODED_SECRET_DISABLED
Agent [baseline] (1.135 s) : 0, 1134793
Total [baseline] (9.174 s) : 0, 9173787
Agent [candidate] (1.139 s) : 0, 1139428
Total [candidate] (9.222 s) : 0, 9221507
section iast_TELEMETRY_OFF
Agent [baseline] (1.146 s) : 0, 1146036
Total [baseline] (9.213 s) : 0, 9212523
Agent [candidate] (1.141 s) : 0, 1141081
Total [candidate] (9.183 s) : 0, 9182672
gantt
title insecure-bank - break down per module: candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section tracing
BytebuddyAgent [baseline] (674.509 ms) : 0, 674509
BytebuddyAgent [candidate] (672.586 ms) : 0, 672586
GlobalTracer [baseline] (240.458 ms) : 0, 240458
GlobalTracer [candidate] (241.196 ms) : 0, 241196
AppSec [baseline] (54.577 ms) : 0, 54577
AppSec [candidate] (54.849 ms) : 0, 54849
Debugger [baseline] (6.933 ms) : 0, 6933
Debugger [candidate] (7.693 ms) : 0, 7693
Remote Config [baseline] (700.5 µs) : 0, 701
Remote Config [candidate] (698.515 µs) : 0, 699
Telemetry [baseline] (8.419 ms) : 0, 8419
Telemetry [candidate] (9.957 ms) : 0, 9957
section iast
BytebuddyAgent [baseline] (788.667 ms) : 0, 788667
BytebuddyAgent [candidate] (793.726 ms) : 0, 793726
GlobalTracer [baseline] (229.502 ms) : 0, 229502
GlobalTracer [candidate] (231.144 ms) : 0, 231144
AppSec [baseline] (55.939 ms) : 0, 55939
AppSec [candidate] (56.549 ms) : 0, 56549
Debugger [baseline] (5.817 ms) : 0, 5817
Debugger [candidate] (5.909 ms) : 0, 5909
Remote Config [baseline] (581.005 µs) : 0, 581
Remote Config [candidate] (600.684 µs) : 0, 601
Telemetry [baseline] (7.871 ms) : 0, 7871
Telemetry [candidate] (7.973 ms) : 0, 7973
IAST [baseline] (23.366 ms) : 0, 23366
IAST [candidate] (22.885 ms) : 0, 22885
section iast_HARDCODED_SECRET_DISABLED
BytebuddyAgent [baseline] (788.715 ms) : 0, 788715
BytebuddyAgent [candidate] (790.016 ms) : 0, 790016
GlobalTracer [baseline] (229.331 ms) : 0, 229331
GlobalTracer [candidate] (231.524 ms) : 0, 231524
AppSec [baseline] (56.24 ms) : 0, 56240
AppSec [candidate] (56.77 ms) : 0, 56770
Debugger [baseline] (5.889 ms) : 0, 5889
Debugger [candidate] (6.035 ms) : 0, 6035
Remote Config [baseline] (580.587 µs) : 0, 581
Remote Config [candidate] (618.244 µs) : 0, 618
Telemetry [baseline] (7.894 ms) : 0, 7894
Telemetry [candidate] (8.01 ms) : 0, 8010
IAST [baseline] (22.689 ms) : 0, 22689
IAST [candidate] (23.0 ms) : 0, 23000
section iast_TELEMETRY_OFF
BytebuddyAgent [baseline] (797.924 ms) : 0, 797924
BytebuddyAgent [candidate] (792.544 ms) : 0, 792544
GlobalTracer [baseline] (231.405 ms) : 0, 231405
GlobalTracer [candidate] (231.228 ms) : 0, 231228
AppSec [baseline] (56.346 ms) : 0, 56346
AppSec [candidate] (56.782 ms) : 0, 56782
Debugger [baseline] (5.942 ms) : 0, 5942
Debugger [candidate] (5.983 ms) : 0, 5983
Remote Config [baseline] (597.71 µs) : 0, 598
Remote Config [candidate] (616.846 µs) : 0, 617
Telemetry [baseline] (7.777 ms) : 0, 7777
Telemetry [candidate] (7.813 ms) : 0, 7813
IAST [baseline] (22.41 ms) : 0, 22410
IAST [candidate] (22.473 ms) : 0, 22473
LoadParameters
See matching parameters
SummaryFound 0 performance improvements and 0 performance regressions! Performance is the same for 12 metrics, 18 unstable metrics. Request duration reports for insecure-bankgantt
title insecure-bank - request duration [CI 0.99] : candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section baseline
no_agent (378.343 µs) : 358, 398
. : milestone, 378,
iast (525.33 µs) : 502, 549
. : milestone, 525,
iast_FULL (735.22 µs) : 712, 759
. : milestone, 735,
iast_GLOBAL (563.855 µs) : 540, 588
. : milestone, 564,
iast_HARDCODED_SECRET_DISABLED (515.332 µs) : 492, 538
. : milestone, 515,
iast_INACTIVE (471.425 µs) : 449, 494
. : milestone, 471,
iast_TELEMETRY_OFF (505.393 µs) : 482, 528
. : milestone, 505,
tracing (457.678 µs) : 436, 480
. : milestone, 458,
section candidate
no_agent (381.268 µs) : 360, 402
. : milestone, 381,
iast (517.98 µs) : 494, 542
. : milestone, 518,
iast_FULL (733.782 µs) : 711, 757
. : milestone, 734,
iast_GLOBAL (567.47 µs) : 543, 592
. : milestone, 567,
iast_HARDCODED_SECRET_DISABLED (524.247 µs) : 501, 547
. : milestone, 524,
iast_INACTIVE (462.241 µs) : 440, 484
. : milestone, 462,
iast_TELEMETRY_OFF (496.862 µs) : 474, 520
. : milestone, 497,
tracing (457.7 µs) : 435, 480
. : milestone, 458,
Request duration reports for petclinicgantt
title petclinic - request duration [CI 0.99] : candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section baseline
no_agent (1.344 ms) : 1325, 1364
. : milestone, 1344,
appsec (1.738 ms) : 1714, 1762
. : milestone, 1738,
appsec_no_iast (1.716 ms) : 1691, 1740
. : milestone, 1716,
code_origins (1.688 ms) : 1661, 1714
. : milestone, 1688,
iast (1.509 ms) : 1484, 1533
. : milestone, 1509,
profiling (1.56 ms) : 1536, 1585
. : milestone, 1560,
tracing (1.484 ms) : 1460, 1509
. : milestone, 1484,
section candidate
no_agent (1.358 ms) : 1338, 1378
. : milestone, 1358,
appsec (1.731 ms) : 1708, 1753
. : milestone, 1731,
appsec_no_iast (1.729 ms) : 1705, 1753
. : milestone, 1729,
code_origins (1.689 ms) : 1662, 1716
. : milestone, 1689,
iast (1.515 ms) : 1491, 1539
. : milestone, 1515,
profiling (1.555 ms) : 1530, 1579
. : milestone, 1555,
tracing (1.5 ms) : 1476, 1525
. : milestone, 1500,
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.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section baseline
no_agent (14.723 s) : 14723000, 14723000
. : milestone, 14723000,
appsec (15.197 s) : 15197000, 15197000
. : milestone, 15197000,
iast (18.836 s) : 18836000, 18836000
. : milestone, 18836000,
iast_GLOBAL (18.016 s) : 18016000, 18016000
. : milestone, 18016000,
profiling (14.841 s) : 14841000, 14841000
. : milestone, 14841000,
tracing (14.944 s) : 14944000, 14944000
. : milestone, 14944000,
section candidate
no_agent (14.963 s) : 14963000, 14963000
. : milestone, 14963000,
appsec (14.845 s) : 14845000, 14845000
. : milestone, 14845000,
iast (18.396 s) : 18396000, 18396000
. : milestone, 18396000,
iast_GLOBAL (18.258 s) : 18258000, 18258000
. : milestone, 18258000,
profiling (15.716 s) : 15716000, 15716000
. : milestone, 15716000,
tracing (14.802 s) : 14802000, 14802000
. : milestone, 14802000,
Execution time for tomcatgantt
title tomcat - execution time [CI 0.99] : candidate=1.49.0-SNAPSHOT~bc7c702e0c, baseline=1.49.0-SNAPSHOT~74633afbc6
dateFormat X
axisFormat %s
section baseline
no_agent (1.479 ms) : 1468, 1491
. : milestone, 1479,
appsec (2.379 ms) : 2332, 2425
. : milestone, 2379,
iast (2.163 ms) : 2104, 2222
. : milestone, 2163,
iast_GLOBAL (2.201 ms) : 2142, 2260
. : milestone, 2201,
profiling (2.023 ms) : 1976, 2070
. : milestone, 2023,
tracing (1.982 ms) : 1937, 2027
. : milestone, 1982,
section candidate
no_agent (1.477 ms) : 1465, 1488
. : milestone, 1477,
appsec (2.381 ms) : 2334, 2428
. : milestone, 2381,
iast (2.156 ms) : 2097, 2215
. : milestone, 2156,
iast_GLOBAL (2.198 ms) : 2139, 2258
. : milestone, 2198,
profiling (2.03 ms) : 1981, 2078
. : milestone, 2030,
tracing (2.008 ms) : 1962, 2054
. : milestone, 2008,
|
65db493
to
e224cd2
Compare
e224cd2
to
bc7c702
Compare
| Package | Type | Package file | Manager | Update | Change | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-logging](https://github.com/googleapis/java-logging) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `3.22.2` -> `3.22.3` | | [com.google.cloud:google-cloud-datastore](https://github.com/googleapis/java-datastore) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.28.0` -> `2.28.1` | | [com.datadoghq:dd-trace-api](https://github.com/datadog/dd-trace-java) | dependencies | misk/gradle/libs.versions.toml | gradle | minor | `1.48.2` -> `1.49.0` | | [software.amazon.awssdk:sdk-core](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | | [software.amazon.awssdk:sqs](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | | [software.amazon.awssdk:dynamodb-enhanced](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | | [software.amazon.awssdk:dynamodb](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | | [software.amazon.awssdk:aws-core](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | | [software.amazon.awssdk:bom](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | | [software.amazon.awssdk:auth](https://aws.amazon.com/sdkforjava) | dependencies | misk/gradle/libs.versions.toml | gradle | patch | `2.31.36` -> `2.31.37` | --- ### Release Notes <details> <summary>googleapis/java-logging (com.google.cloud:google-cloud-logging)</summary> ### [`v3.22.3`](https://github.com/googleapis/java-logging/blob/HEAD/CHANGELOG.md#3223-2025-05-06) ##### Bug Fixes - **deps:** Update the Java code generator (gapic-generator-java) to 2.56.3 ([844f4fa](googleapis/java-logging@844f4fa)) ##### Dependencies - Update dependency com.google.cloud:sdk-platform-java-config to v3.46.3 ([#​1801](googleapis/java-logging#1801)) ([d7aa7bc](googleapis/java-logging@d7aa7bc)) - Update dependency com.google.cloud:sdk-platform-java-config to v3.47.0 ([#​1803](googleapis/java-logging#1803)) ([5967ffe](googleapis/java-logging@5967ffe)) - Update googleapis/sdk-platform-java action to v2.57.0 ([#​1804](googleapis/java-logging#1804)) ([e9a27ec](googleapis/java-logging@e9a27ec)) </details> <details> <summary>googleapis/java-datastore (com.google.cloud:google-cloud-datastore)</summary> ### [`v2.28.1`](https://github.com/googleapis/java-datastore/blob/HEAD/CHANGELOG.md#2281-2025-05-06) ##### Dependencies - Update dependency com.google.cloud:sdk-platform-java-config to v3.47.0 ([#​1841](googleapis/java-datastore#1841)) ([ac393e6](googleapis/java-datastore@ac393e6)) - Update googleapis/sdk-platform-java action to v2.57.0 ([#​1842](googleapis/java-datastore#1842)) ([0745906](googleapis/java-datastore@0745906)) </details> <details> <summary>datadog/dd-trace-java (com.datadoghq:dd-trace-api)</summary> ### [`v1.49.0`](https://github.com/DataDog/dd-trace-java/releases/tag/v1.49.0): 1.49.0 ### Components #### Configuration at Runtime - ✨ Add process tags as list to remote config payload ([#​8705](DataDog/dd-trace-java#8705) - [@​amarziali](https://github.com/amarziali)) #### Continuous Integration Visibility - 🐛 Add span propagation for Pekko scheduled tasks ([#​8765](DataDog/dd-trace-java#8765) - [@​nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog)) - ✨ Update test.retry_reason to use full name of the feature ([#​8689](DataDog/dd-trace-java#8689) - [@​daniel-mohedano](https://github.com/daniel-mohedano)) - 🧹 Remove unused TestEventsHandler methods ([#​8674](DataDog/dd-trace-java#8674) - [@​nikita-tkachenko-datadog](https://github.com/nikita-tkachenko-datadog)) #### Dynamic Instrumentation - 🐛 Fix exclude identifiers normalization ([#​8742](DataDog/dd-trace-java#8742) - [@​jpbempel](https://github.com/jpbempel)) - ✨ Make source file tracking asynchronous ([#​8684](DataDog/dd-trace-java#8684) - [@​jpbempel](https://github.com/jpbempel)) - ✨ Add scope filtering for symbol extraction ([#​8676](DataDog/dd-trace-java#8676) - [@​jpbempel](https://github.com/jpbempel)) - ✨ Add support for [@​key](https://github.com/key) and [@​value](https://github.com/value) for Map filtering ([#​8669](DataDog/dd-trace-java#8669) - [@​jpbempel](https://github.com/jpbempel)) #### Library Injection - ✨ Add system property to force injection of the tracing library even though multiple javaagents have been detected ([#​8697](DataDog/dd-trace-java#8697) - [@​cecile75](https://github.com/cecile75)) #### Metrics - ✨ Allow dogstatsd port to be configurable with DD_DOGSTATSD_PORT ([#​8693](DataDog/dd-trace-java#8693) - [@​randomanderson](https://github.com/randomanderson)) #### Profiling - ✨ Bump ddprof-java to 1.25.1 ([#​8750](DataDog/dd-trace-java#8750) - [@​jbachorik](https://github.com/jbachorik)) - 🐛 Remove cleanup-on-shutdown for temporary files ([#​8746](DataDog/dd-trace-java#8746) - [@​jbachorik](https://github.com/jbachorik)) - ✨⚡ Replace a regex-based SMAP parser with a hand-crafted one ([#​8730](DataDog/dd-trace-java#8730) - [@​jbachorik](https://github.com/jbachorik)) - ✨ Improve error reporting on profiler startup ([#​8714](DataDog/dd-trace-java#8714) - [@​jbachorik](https://github.com/jbachorik)) - ✨ Exclude ProxyLeakTask exception from exception profiling ([#​8666](DataDog/dd-trace-java#8666) - [@​jbachorik](https://github.com/jbachorik)) - ✨ Use jvmstat for JDKs 9+ programmatically ([#​8641](DataDog/dd-trace-java#8641) - [@​MattAlp](https://github.com/MattAlp)) #### Telemetry - ✨ Allow dogstatsd port to be configurable with DD_DOGSTATSD_PORT ([#​8693](DataDog/dd-trace-java#8693) - [@​randomanderson](https://github.com/randomanderson)) - 🐛 Fix appsec.waf.requests telemetry metric ([#​8644](DataDog/dd-trace-java#8644) - [@​jandro996](https://github.com/jandro996)) #### Tracer core - ✨ Exclude jackson afterburner dynamic classes from instrumentation ([#​8747](DataDog/dd-trace-java#8747) - [@​amarziali](https://github.com/amarziali)) - ✨ Introduce Java 8 bytecode bridge for instrumentation API ([#​8736](DataDog/dd-trace-java#8736) - [@​PerfectSlayer](https://github.com/PerfectSlayer)) - ⚡🧹 Use byte-buddy classes optimized for Java8+ ([#​8735](DataDog/dd-trace-java#8735) - [@​mcculls](https://github.com/mcculls)) - 🐛 Do not set the hibernate or datanucleus span service name when disabled ([#​8727](DataDog/dd-trace-java#8727) - [@​ygree](https://github.com/ygree)) - ✨ Update bytebuddy and ASM to support JDK 24 ([#​8720](DataDog/dd-trace-java#8720) - [@​sarahchen6](https://github.com/sarahchen6)) - 🐛 Turn off JDK socket support by default ([#​8715](DataDog/dd-trace-java#8715) - [@​mcculls](https://github.com/mcculls)) - 🐛 Log warning when trace buffer overflow occurs ([#​8712](DataDog/dd-trace-java#8712) - [@​ygree](https://github.com/ygree)) - ✨🧪 Introducing an internal integration name ([#​8708](DataDog/dd-trace-java#8708) - [@​amarziali](https://github.com/amarziali)) - ✨ Add process tags to client stats payload ([#​8704](DataDog/dd-trace-java#8704) - [@​amarziali](https://github.com/amarziali)) - ✨ Collect process tags for tracing ([#​8698](DataDog/dd-trace-java#8698) - [@​amarziali](https://github.com/amarziali)) - ✨ Stable Config file: target system properties in process_arguments and support template variables in YamlParser ([#​8690](DataDog/dd-trace-java#8690) - [@​mtoffl01](https://github.com/mtoffl01)) - ✨⚡ Use prefix trie for proxy ignores ([#​8678](DataDog/dd-trace-java#8678) - [@​amarziali](https://github.com/amarziali)) - ✨ Allow agent to be automatically injected when running aside Log4J patch agent ([#​8648](DataDog/dd-trace-java#8648) - [@​paullegranddc](https://github.com/paullegranddc)) - ✨ Use jvmstat for JDKs 9+ programmatically ([#​8641](DataDog/dd-trace-java#8641) - [@​MattAlp](https://github.com/MattAlp)) #### Tracer internal logging - 🐛 Delete print line ([#​8686](DataDog/dd-trace-java#8686) - [@​sarahchen6](https://github.com/sarahchen6)) ### Instrumentations #### Akka instrumentation - 🐛 Handle reentrant scope cleanup in Akka/Pekko actor instrumentations ([#​8722](DataDog/dd-trace-java#8722) - [@​mcculls](https://github.com/mcculls)) #### Apache Spark instrumentation - ✨ Use OpenLineage root parent information to generate trace id ([#​8726](DataDog/dd-trace-java#8726) - [@​mobuchowski](https://github.com/mobuchowski)) - ✨ Spark job cancellation no longer marks application as failed ([#​8701](DataDog/dd-trace-java#8701) - [@​paul-laffon-dd](https://github.com/paul-laffon-dd)) #### JDBC instrumentation - 💡 Add support for sybase tds jdbc driver ([#​8764](DataDog/dd-trace-java#8764) - [@​amarziali](https://github.com/amarziali)) #### Kotlin instrumentation - 🐛 Take defensive copy of parent scope stack when closing nested coroutines ([#​8749](DataDog/dd-trace-java#8749) - [@​mcculls](https://github.com/mcculls)) #### Reactor instrumentation - ✨⚡ Do not inspect reactor context when not needed ([#​8745](DataDog/dd-trace-java#8745) - [@​amarziali](https://github.com/amarziali)) </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. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- 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: 795f347ae34d056efc1194c2f606cee7bca1beea
What Does This Do
This PR applies some short-term defensive fixes:
newScopeState().fetchFromActive()
code path in favour ofoldScopeState()
which does bothMotivation
The parent coroutine scope stack is only used for cleanup purposes in certain situations and using a defensive copy avoids potential concurrent modification issues when different child coroutines are closed at the same time across multiple threads.
Additional Notes
This code is being refactored as part of further context improvements, so these defensive fixes are only needed in the short-term.
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: APMS-15615