Skip to content

fix(core): retire finished spans without losing context - #9292

Draft
BridgeAR wants to merge 6 commits into
masterfrom
BridgeAR/2026-07-10-retire-span-context
Draft

fix(core): retire finished spans without losing context#9292
BridgeAR wants to merge 6 commits into
masterfrom
BridgeAR/2026-07-10-retire-span-context

Conversation

@BridgeAR

Copy link
Copy Markdown
Member

Summary

Long-lived async resources can retain finished middleware spans and their parent chains after export, making retained heap grow with request count. This retires completed request stores to a compact propagation facade after serialization and response listeners complete.

Why

Nulling context at response finish breaks late work such as res.end(); await work(). Keeping the original span preserves context but leaves the retention path intact. The facade preserves trace, baggage, log, and OTel propagation without retaining the original spans.

Fixes: #9227

@dd-octo-sts

dd-octo-sts Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Overall package size

Self size: 6.72 MB
Deduped: 7.38 MB
No deduping: 7.38 MB

Dependency sizes | name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.3.1 | 122.62 kB | 438.86 kB | | opentracing | 0.14.7 | 194.81 kB | 194.81 kB | | dc-polyfill | 0.1.11 | 25.74 kB | 25.74 kB |

🤖 This report was automatically generated by heaviest-objects-in-the-universe

@datadog-datadog-prod-us1

datadog-datadog-prod-us1 Bot commented Jul 10, 2026

Copy link
Copy Markdown

Tests

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
Patch Coverage: 99.10%
Overall Coverage: 96.58% (+0.01%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 2dfaa24 | Docs | Datadog PR Page | Give us feedback!

@pr-commenter

pr-commenter Bot commented Jul 10, 2026

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2026-07-14 00:28:16

Comparing candidate commit 2dfaa24 in PR branch BridgeAR/2026-07-10-retire-span-context with baseline commit 8bcc0d2 in branch master.

📊 Benchmarking dashboard

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

Explanation

This is an A/B test comparing a candidate commit's performance against that of a baseline commit. Performance changes are noted in the tables below as:

  • 🟩 = significantly better candidate vs. baseline
  • 🟥 = significantly worse candidate vs. baseline

We compute a confidence interval (CI) over the relative difference of means between metrics from the candidate and baseline commits, considering the baseline as the reference.

If the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD), the change is considered significant.

Feel free to reach out to #apm-benchmarking-platform on Slack if you have any questions.

More details about the CI and significant changes

You can imagine this CI as a range of values that is likely to contain the true difference of means between the candidate and baseline commits.

CIs of the difference of means are often centered around 0%, because often changes are not that big:

---------------------------------(------|---^--------)-------------------------------->
                              -0.6%    0%  0.3%     +1.2%
                                 |          |        |
         lower bound of the CI --'          |        |
sample mean (center of the CI) -------------'        |
         upper bound of the CI ----------------------'

As described above, a change is considered significant if the CI is entirely outside the configured SIGNIFICANT_IMPACT_THRESHOLD (or the deprecated UNCONFIDENCE_THRESHOLD).

For instance, for an execution time metric, this confidence interval indicates a significantly worse performance:

----------------------------------------|---------|---(---------^---------)---------->
                                       0%        1%  1.3%      2.2%      3.1%
                                                  |   |         |         |
       significant impact threshold --------------'   |         |         |
                      lower bound of CI --------------'         |         |
       sample mean (center of the CI) --------------------------'         |
                      upper bound of CI ----------------------------------'

scenario:span-retention-async-resource-24

  • 🟩 cpu_user_time [-1157.347ms; -373.265ms] or [-14.266%; -4.601%]
  • 🟩 execution_time [-1256.196ms; -405.884ms] or [-14.019%; -4.530%]
  • 🟩 instructions [-1493.4M instructions; -485.0M instructions] or [-6.272%; -2.037%]
  • 🟩 throughput [+72.197op/s; +225.220op/s] or [+4.239%; +13.224%]

scenario:span-retention-async-resource-26

  • 🟩 execution_time [-1265.731ms; -397.584ms] or [-14.331%; -4.502%]
  • 🟩 instructions [-1.9G instructions; -0.6G instructions] or [-7.788%; -2.301%]
  • 🟩 throughput [+72.162op/s; +235.534op/s] or [+4.178%; +13.636%]

scenario:span-retention-long-timer-24

  • 🟩 cpu_user_time [-1134.193ms; -361.032ms] or [-13.838%; -4.405%]
  • 🟩 execution_time [-1232.994ms; -393.557ms] or [-13.623%; -4.348%]
  • 🟩 instructions [-1.6G instructions; -0.5G instructions] or [-6.726%; -2.115%]
  • 🟩 throughput [+68.401op/s; +217.073op/s] or [+4.056%; +12.871%]

scenario:span-retention-long-timer-26

  • 🟩 cpu_user_time [-1095.808ms; -350.751ms] or [-13.458%; -4.308%]
  • 🟩 execution_time [-1185.722ms; -380.429ms] or [-13.199%; -4.235%]
  • 🟩 instructions [-1.5G instructions; -0.5G instructions] or [-6.225%; -2.011%]
  • 🟩 throughput [+67.362op/s; +211.460op/s] or [+3.968%; +12.458%]

scenario:span-retention-request-only-20

  • 🟩 cpu_user_time [-2.113s; -0.572s] or [-11.923%; -3.226%]
  • 🟩 execution_time [-2.221s; -0.604s] or [-11.427%; -3.108%]
  • 🟩 throughput [+63.247op/s; +237.029op/s] or [+3.053%; +11.440%]

Unstable benchmarks

These benchmarks have a confidence interval too wide to call a change; treat them as noise rather than signal.

scenario:appsec-appsec-enabled-24

  • unstable execution_time [-208.006ms; +204.172ms] or [-7.842%; +7.697%]

scenario:appsec-appsec-enabled-26

  • unstable execution_time [-241.560ms; +247.024ms] or [-9.498%; +9.713%]

scenario:appsec-appsec-enabled-with-attacks-24

  • unstable execution_time [-162.617ms; +171.396ms] or [-5.185%; +5.465%]

scenario:appsec-appsec-enabled-with-attacks-26

  • unstable execution_time [-186.190ms; +182.815ms] or [-6.409%; +6.292%]

scenario:appsec-control-20

  • unstable execution_time [-113.149ms; +138.362ms] or [-6.828%; +8.349%]

scenario:appsec-control-24

  • unstable execution_time [-108.974ms; +111.732ms] or [-8.822%; +9.045%]

scenario:appsec-control-26

  • unstable execution_time [-127.334ms; +137.575ms] or [-10.210%; +11.031%]

scenario:appsec-iast-no-vulnerability-control-20

  • unstable execution_time [-17.553ms; +9.082ms] or [-6.813%; +3.525%]

scenario:appsec-iast-with-vulnerability-iast-enabled-always-active-20

  • unstable execution_time [-30.378ms; +34.259ms] or [-5.476%; +6.176%]

scenario:debugger-line-probe-with-snapshot-default-24

  • unstable cpu_user_time [-2.620s; +0.171s] or [-29.377%; +1.917%]
  • unstable execution_time [-2.646s; +0.171s] or [-27.450%; +1.773%]
  • unstable instructions [-22.3G instructions; +1.4G instructions] or [-30.533%; +1.961%]
  • unstable throughput [-27.150op/s; +748.189op/s] or [-0.785%; +21.620%]

scenario:debugger-line-probe-with-snapshot-default-26

  • unstable cpu_user_time [-2158.999ms; +3336.635ms] or [-22.932%; +35.440%]
  • unstable execution_time [-2302.435ms; +3561.303ms] or [-22.712%; +35.130%]
  • unstable instructions [-18.6G instructions; +29.3G instructions] or [-23.808%; +37.506%]
  • unstable max_rss_usage [-5.688MB; +10.821MB] or [-3.558%; +6.769%]
  • unstable throughput [-746.635op/s; +492.109op/s] or [-22.996%; +15.157%]

scenario:debugger-line-probe-with-snapshot-minimal-24

  • unstable cpu_user_time [-1633.628ms; +330.086ms] or [-19.580%; +3.956%]
  • unstable execution_time [-1662.575ms; +322.137ms] or [-18.357%; +3.557%]
  • unstable instructions [-13.8G instructions; +2.8G instructions] or [-20.287%; +4.113%]
  • unstable throughput [-78.431op/s; +502.303op/s] or [-2.170%; +13.896%]

scenario:debugger-line-probe-with-snapshot-minimal-26

  • unstable cpu_user_time [-2660.916ms; +4206.207ms] or [-27.841%; +44.010%]
  • unstable execution_time [-2835.424ms; +4396.195ms] or [-27.575%; +42.755%]
  • unstable instructions [-23.1G instructions; +37.0G instructions] or [-28.969%; +46.459%]
  • unstable max_rss_usage [-8.313MB; +13.325MB] or [-5.229%; +8.381%]
  • unstable throughput [-839.947op/s; +552.937op/s] or [-25.973%; +17.098%]

scenario:debugger-line-probe-without-snapshot-24

  • unstable cpu_user_time [-2671.495ms; +2651.297ms] or [-30.249%; +30.020%]
  • unstable execution_time [-2671.871ms; +2643.102ms] or [-27.947%; +27.646%]
  • unstable instructions [-22896.5M instructions; +22913.6M instructions] or [-31.639%; +31.663%]
  • unstable max_rss_usage [-11242.175KB; +11034.975KB] or [-7.083%; +6.952%]
  • unstable throughput [-700.230op/s; +745.673op/s] or [-20.066%; +21.368%]

scenario:debugger-line-probe-without-snapshot-26

  • unstable cpu_user_time [-1832.345ms; +586.847ms] or [-19.535%; +6.257%]
  • unstable execution_time [-1848.408ms; +581.704ms] or [-18.294%; +5.757%]
  • unstable instructions [-16.1G instructions; +5.2G instructions] or [-20.596%; +6.675%]
  • unstable throughput [-127.212op/s; +405.936op/s] or [-3.916%; +12.498%]

scenario:dogstatsd-with-tags-20

  • unstable cpu_user_time [-277.319ms; +439.786ms] or [-5.786%; +9.176%]
  • unstable execution_time [-282.538ms; +449.997ms] or [-5.804%; +9.244%]
  • unstable throughput [-153880.590op/s; +98190.807op/s] or [-8.918%; +5.690%]

scenario:plugin-graphql-long-with-depth-off-20

  • unstable max_rss_usage [-7135.704KB; +7421.990KB] or [-5.511%; +5.732%]

scenario:plugin-graphql-long-with-depth-on-max-20

  • unstable cpu_user_time [-666.979ms; +693.271ms] or [-5.196%; +5.401%]
  • unstable execution_time [-672.487ms; +691.126ms] or [-5.127%; +5.269%]
  • unstable throughput [-3.183op/s; +3.081op/s] or [-5.189%; +5.023%]

scenario:plugin-pg-service-24

  • unstable cpu_usage_percentage [-9.946%; +6.274%]
  • unstable execution_time [-172.990ms; +269.795ms] or [-10.223%; +15.943%]
  • unstable throughput [-374019.038op/s; +242617.040op/s] or [-10.385%; +6.736%]

scenario:span-retention-async-resource-20

  • unstable cpu_user_time [-3.453s; -1.100s] or [-26.101%; -8.314%]
  • unstable execution_time [-3.561s; -1.135s] or [-24.892%; -7.934%]
  • unstable instructions [-9.6G instructions; -3.1G instructions] or [-26.051%; -8.529%]
  • unstable max_rss_usage [-267.361MB; -87.669MB] or [-76.283%; -25.014%]
  • unstable throughput [+84.261op/s; +264.215op/s] or [+7.779%; +24.393%]

scenario:span-retention-async-resource-24

  • unstable max_rss_usage [-186.106MB; -60.976MB] or [-46.875%; -15.358%]

scenario:span-retention-async-resource-26

  • unstable cpu_user_time [-1166.405ms; -357.133ms] or [-14.576%; -4.463%]
  • unstable max_rss_usage [-183.021MB; -59.998MB] or [-51.807%; -16.983%]

scenario:span-retention-long-timer-20

  • unstable cpu_user_time [-3.416s; -1.090s] or [-25.431%; -8.116%]
  • unstable execution_time [-3.535s; -1.130s] or [-24.354%; -7.782%]
  • unstable instructions [-9.1G instructions; -3.0G instructions] or [-24.481%; -8.009%]
  • unstable max_rss_usage [-267.008MB; -87.561MB] or [-75.907%; -24.893%]
  • unstable throughput [+81.396op/s; +255.083op/s] or [+7.631%; +23.914%]

scenario:span-retention-long-timer-24

  • unstable max_rss_usage [-186.965MB; -61.281MB] or [-46.781%; -15.333%]

scenario:span-retention-long-timer-26

  • unstable max_rss_usage [-183.666MB; -60.228MB] or [-51.740%; -16.967%]

scenario:span-retention-request-only-20

  • unstable max_rss_usage [-52.290MB; -17.134MB] or [-27.477%; -9.004%]

scenario:test-optimization-large-suite-20

  • unstable max_rss_usage [-4.490MB; +7.543MB] or [-5.551%; +9.324%]

@codecov

codecov Bot commented Jul 10, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 99.10233% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 96.61%. Comparing base (8bcc0d2) to head (2dfaa24).

Files with missing lines Patch % Lines
packages/dd-trace/src/active-span.js 98.74% 5 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #9292      +/-   ##
==========================================
+ Coverage   96.60%   96.61%   +0.01%     
==========================================
  Files         919      920       +1     
  Lines      121692   122181     +489     
  Branches    21299    20921     -378     
==========================================
+ Hits       117562   118049     +487     
- Misses       4130     4132       +2     
Flag Coverage Δ
aiguard 53.50% <48.25%> (-0.11%) ⬇️
aiguard-integration 57.16% <70.78%> (+0.15%) ⬆️
apm-bucket-0 53.72% <48.25%> (-0.11%) ⬇️
apm-bucket-1 57.92% <49.67%> (-0.21%) ⬇️
apm-bucket-2 56.28% <69.54%> (+0.12%) ⬆️
apm-capabilities-tracing 60.58% <94.95%> (+0.23%) ⬆️
apm-integrations-aerospike 52.60% <25.10%> (-0.39%) ⬇️
apm-integrations-confluentinc-kafka-javascript 56.90% <48.47%> (-0.21%) ⬇️
apm-integrations-couchbase 53.20% <47.37%> (-0.12%) ⬇️
apm-integrations-http 57.89% <50.70%> (-0.12%) ⬇️
apm-integrations-kafkajs 57.61% <48.47%> (-0.15%) ⬇️
apm-integrations-next 54.18% <49.03%> (-0.11%) ⬇️
apm-integrations-prisma 54.13% <51.20%> (-0.09%) ⬇️
apm-integrations-tedious 52.98% <47.53%> (-0.11%) ⬇️
appsec 68.82% <49.46%> (-0.17%) ⬇️
appsec-express_fastify_graphql 65.78% <71.71%> (+0.06%) ⬆️
appsec-integration 52.13% <71.71%> (+0.14%) ⬆️
appsec-kafka_ldapjs_lodash 58.99% <49.46%> (-0.14%) ⬇️
appsec-mongodb-core_mongoose_mysql 62.34% <71.39%> (+0.05%) ⬆️
appsec-next 52.82% <49.25%> (-0.08%) ⬇️
appsec-node-serialize_passport_postgres 61.98% <71.19%> (+0.07%) ⬆️
appsec-sourcing_stripe_template 60.24% <49.38%> (-0.14%) ⬇️
debugger 65.57% <51.44%> (-0.18%) ⬇️
instrumentations-bucket-0 48.73% <46.72%> (-0.07%) ⬇️
instrumentations-bucket-1 55.15% <69.75%> (+0.14%) ⬆️
instrumentations-bucket-10 56.54% <48.76%> (-0.13%) ⬇️
instrumentations-bucket-11 48.72% <46.72%> (-0.07%) ⬇️
instrumentations-bucket-12 48.84% <47.75%> (-0.06%) ⬇️
instrumentations-bucket-13 48.66% <46.72%> (-0.07%) ⬇️
instrumentations-bucket-2 49.72% <48.55%> (-0.07%) ⬇️
instrumentations-bucket-3 53.78% <49.17%> (-0.10%) ⬇️
instrumentations-bucket-4 49.14% <46.72%> (-0.08%) ⬇️
instrumentations-bucket-5 52.99% <50.20%> (-0.07%) ⬇️
instrumentations-bucket-6 55.53% <49.46%> (-0.12%) ⬇️
instrumentations-bucket-7 53.56% <50.39%> (-0.10%) ⬇️
instrumentations-bucket-8 54.82% <69.75%> (+0.14%) ⬆️
instrumentations-bucket-9 56.03% <48.76%> (-0.12%) ⬇️
instrumentations-instrumentation-couchbase 47.86% <23.14%> (-0.37%) ⬇️
instrumentations-integration-esbuild 34.09% <44.39%> (+0.10%) ⬆️
llmobs-ai_anthropic_bedrock 57.63% <47.96%> (-0.14%) ⬇️
llmobs-bucket-1 56.90% <47.96%> (-0.12%) ⬇️
llmobs-openai 57.46% <47.96%> (-0.14%) ⬇️
llmobs-sdk 59.82% <50.00%> (-0.18%) ⬇️
llmobs-vertex-ai 54.13% <46.89%> (-0.13%) ⬇️
master-coverage 96.61% <99.10%> (?)
openfeature 54.81% <69.54%> (+0.19%) ⬆️
openfeature-unit 49.80% <46.72%> (-0.08%) ⬇️
platform-core_esbuild_instrumentations-misc 38.53% <44.82%> (+0.04%) ⬆️
platform-integration 62.35% <72.58%> (+0.12%) ⬆️
platform-shimmer_unit-guardrails_webpack 37.36% <44.72%> (+0.04%) ⬆️
plugins-bucket-0 53.14% <49.46%> (-0.08%) ⬇️
plugins-bucket-1 55.27% <69.75%> (+0.19%) ⬆️
plugins-bucket-11 55.54% <49.58%> (-0.10%) ⬇️
plugins-bucket-18 56.99% <48.14%> (-0.13%) ⬇️
plugins-bucket-19 55.56% <69.95%> (+0.14%) ⬆️
plugins-bucket-20 57.59% <69.75%> (+0.10%) ⬆️
plugins-bucket-4 53.81% <47.41%> (-0.09%) ⬇️
plugins-bullmq_cassandra_cookie 57.25% <47.75%> (-0.15%) ⬇️
plugins-cookie-parser_crypto_dd-trace-api 52.27% <48.25%> (-0.10%) ⬇️
plugins-fetch_fs_generic-pool 54.41% <49.89%> (-0.10%) ⬇️
plugins-google-cloud-pubsub_grpc_handlebars 59.99% <70.38%> (+0.08%) ⬆️
plugins-hapi_hono_ioredis 56.03% <69.75%> (+0.12%) ⬆️
plugins-jest_knex_langgraph 51.62% <47.37%> (-0.10%) ⬇️
plugins-ldapjs_light-my-request_limitd-client 53.38% <50.10%> (-0.09%) ⬇️
plugins-lodash_mariadb_memcached 54.15% <48.25%> (-0.11%) ⬇️
plugins-moleculer_mongodb_mongodb-core 57.18% <48.17%> (-0.15%) ⬇️
plugins-mongoose_multer_mysql 54.63% <47.75%> (-0.12%) ⬇️
plugins-mysql2_nats_node-serialize 56.12% <48.47%> (-0.14%) ⬇️
plugins-opensearch_passport-http_pino 54.98% <48.17%> (-0.13%) ⬇️
plugins-postgres_process_pug 54.22% <48.25%> (-0.12%) ⬇️
plugins-redis_router_sequelize 57.43% <77.77%> (+0.35%) ⬆️
plugins-test-and-upstream-rhea_undici_url 56.93% <49.89%> (-0.15%) ⬇️
plugins-valkey_vm_winston 53.86% <47.96%> (-0.04%) ⬇️
plugins-ws 54.72% <47.96%> (-0.13%) ⬇️
profiling 58.10% <49.25%> (-0.14%) ⬇️
serverless-aws-sdk-aws-sdk 50.64% <47.96%> (-0.07%) ⬇️
serverless-aws-sdk-bedrockruntime 50.65% <46.89%> (-0.08%) ⬇️
serverless-aws-sdk-client 51.93% <47.75%> (-0.09%) ⬇️
serverless-aws-sdk-dynamodb 51.70% <46.89%> (-0.10%) ⬇️
serverless-aws-sdk-eventbridge 46.28% <46.91%> (-0.03%) ⬇️
serverless-aws-sdk-kinesis 54.64% <47.96%> (-0.11%) ⬇️
serverless-aws-sdk-lambda 52.74% <47.75%> (-0.10%) ⬇️
serverless-aws-sdk-s3 51.49% <46.89%> (-0.09%) ⬇️
serverless-aws-sdk-serverless-peer-service 54.66% <47.96%> (-0.15%) ⬇️
serverless-aws-sdk-sns 55.41% <47.96%> (-0.12%) ⬇️
serverless-aws-sdk-sqs 55.83% <48.17%> (-0.12%) ⬇️
serverless-aws-sdk-stepfunctions 51.22% <47.75%> (-0.08%) ⬇️
serverless-aws-sdk-util 48.46% <46.72%> (-0.07%) ⬇️
serverless-bucket-0 54.86% <24.62%> (-0.37%) ⬇️
serverless-bucket-1 55.92% <49.46%> (-0.13%) ⬇️
test-optimization-cucumber 72.95% <73.66%> (+0.01%) ⬆️
test-optimization-cypress 66.37% <69.75%> (+0.09%) ⬆️
test-optimization-jest 74.25% <73.66%> (-0.03%) ⬇️
test-optimization-mocha 74.69% <73.66%> (+0.07%) ⬆️
test-optimization-playwright-playwright-atr 61.66% <69.75%> (+0.11%) ⬆️
test-optimization-playwright-playwright-efd 61.84% <69.75%> (-0.05%) ⬇️
test-optimization-playwright-playwright-final-status 61.80% <69.75%> (+0.11%) ⬆️
test-optimization-playwright-playwright-impacted-tests 61.53% <69.75%> (+0.28%) ⬆️
test-optimization-playwright-playwright-reporting 61.43% <69.75%> (+0.18%) ⬆️
test-optimization-playwright-playwright-test-management 62.33% <69.75%> (-0.01%) ⬇️
test-optimization-playwright-playwright-test-span 61.57% <69.75%> (+0.06%) ⬆️
test-optimization-selenium 60.76% <69.95%> (-0.05%) ⬇️
test-optimization-testopt 59.25% <71.52%> (+0.18%) ⬆️
test-optimization-vitest 71.60% <73.66%> (+0.07%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@BridgeAR
BridgeAR force-pushed the BridgeAR/2026-07-10-retire-span-context branch 3 times, most recently from 2a7ebf3 to b861c04 Compare July 13, 2026 20:08
BridgeAR added 5 commits July 14, 2026 01:31
Long-lived async resources can retain finished middleware spans and their parent chains after export, making retained heap grow with request count.

The original span remains active until serialization and response listeners complete. Retained resources then keep a compact propagation facade, so late work preserves trace and baggage context without pinning the span graph.

Fixes: #9227
Finished spans must remain live until trace serialization completes. Trace-level draining preserves that ordering without retirement work on every formatted span.

The exporting-pipeline format benchmark improved from 1.367 s to 1.213 s on Node v24.18.0 / V8 13.6.233.17-node.50 (200k operations, 3 warmups, 7 runs).
Long-lived async resources retain finished middleware spans after trace erasure. Keep only the propagation state in the retired facade until late work requests a context, while preserving baggage and propagation metadata.
The BP Sirun converter rejects custom heap gauges during result conversion. Keep heap growth as a candidate-side threshold assertion and leave baseline runs available for built-in RSS comparisons.
The request-only control measured forced full GCs inside its timed window, making the benchmark report GC overhead as a default request regression. Keep forced GC for retained-resource heap checks, but measure ordinary request throughput and RSS without it.
@BridgeAR
BridgeAR force-pushed the BridgeAR/2026-07-10-retire-span-context branch from b861c04 to f75c4f7 Compare July 13, 2026 23:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG]: express.middleware spans retained unbounded via AsyncLocalStorage frame capture → heap OOM

1 participant