Skip to content

fix(graphql): record reused non-JIT resolver errors - #10082

Merged
BridgeAR merged 2 commits into
masterfrom
BridgeAR/2026-08-31-graphql-non-jit-resolver-errors
Sep 2, 2026
Merged

BridgeAR merged 2 commits into
masterfrom
BridgeAR/2026-08-31-graphql-non-jit-resolver-errors

Conversation

@BridgeAR

@BridgeAR BridgeAR commented Aug 31, 2026

Copy link
Copy Markdown
Member

Collapsed non-JIT fields reuse one span, but a sibling rejection could leave that span and its resolve hook successful.

GraphQL normalizes resolver failures before execution completes. Recording the error at that boundary keeps successful reused calls on the existing collapsed fast path. The first error wins, and a falsy rejection receives a real Error. The resolve hook still runs once before the execute hook.

@dd-octo-sts

dd-octo-sts Bot commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Overall package size

Self size: 8.64 MB
Deduped: 9.31 MB
No deduping: 9.31 MB

Dependency sizes | name | version | self size | total size | |------|---------|-----------|------------| | import-in-the-middle | 3.4.0 | 127.33 kB | 447.04 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 Aug 31, 2026

Copy link
Copy Markdown

Tests

All CI checks and tests passed. Datadog automation helped this PR pass.

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🔄 Datadog retried 1 test - 1 passed on retry View in Datadog

🎯 Code Coverage (details)
Patch Coverage: 100.00%
Overall Coverage: 98.63% (+0.00%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 754c778 | Docs | View more details | Give us feedback!

@pr-commenter

pr-commenter Bot commented Aug 31, 2026

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2026-09-01 09:19:13

Comparing candidate commit 754c778 in PR branch BridgeAR/2026-08-31-graphql-non-jit-resolver-errors with baseline commit 14024a4 in branch master.

📊 Benchmarking dashboard

Found 0 performance improvements and 0 performance regressions! Performance is the same for 2300 metrics, 10 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 ----------------------------------'

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-20

  • unstable max_rss_usage [-20.802MB; +33.571MB] or [-11.849%; +19.122%]

scenario:appsec-iast-with-vulnerability-iast-enabled-default-config-20

  • unstable max_rss_usage [-30.643MB; +20.196MB] or [-8.207%; +5.409%]

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

  • unstable max_rss_usage [-17.958MB; +6.883MB] or [-7.329%; +2.809%]

scenario:dogstatsd-with-tags-20

  • unstable cpu_user_time [-302.373ms; +380.308ms] or [-6.064%; +7.627%]
  • unstable execution_time [-300.679ms; +377.166ms] or [-5.937%; +7.447%]
  • unstable throughput [-126162.358op/s; +100657.793op/s] or [-7.615%; +6.076%]

scenario:plugin-claude-agent-sdk-compact-stream-scan-26

  • unstable cpu_usage_percentage [-5.536%; +5.183%]

scenario:plugin-pg-service-26

  • unstable cpu_usage_percentage [-5.535%; +7.491%]
  • unstable execution_time [-102.700ms; +81.006ms] or [-10.840%; +8.550%]
  • unstable throughput [-460056.993op/s; +463191.632op/s] or [-7.070%; +7.118%]

@codecov

codecov Bot commented Aug 31, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.62%. Comparing base (14024a4) to head (754c778).
⚠️ Report is 6 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff            @@
##           master   #10082    +/-   ##
========================================
  Coverage   98.62%   98.62%            
========================================
  Files         996      997     +1     
  Lines      152043   152260   +217     
  Branches    13193    12671   -522     
========================================
+ Hits       149956   150174   +218     
+ Misses       2087     2086     -1     
Flag Coverage Δ
aiguard 63.20% <100.00%> (+0.04%) ⬆️
aiguard-integration 59.06% <100.00%> (+0.06%) ⬆️
apm-bucket-0 62.56% <100.00%> (+0.04%) ⬆️
apm-bucket-1 67.99% <100.00%> (+0.03%) ⬆️
apm-bucket-2 67.55% <100.00%> (+0.03%) ⬆️
apm-bucket-3 64.41% <100.00%> (+0.04%) ⬆️
apm-capabilities-tracing 62.56% <60.08%> (-0.01%) ⬇️
apm-integrations-aerospike 60.58% <100.00%> (+0.05%) ⬆️
apm-integrations-confluentinc-kafka-javascript 66.65% <100.00%> (+0.04%) ⬆️
apm-integrations-couchbase 61.09% <100.00%> (+0.05%) ⬆️
apm-integrations-http 66.27% <100.00%> (+0.03%) ⬆️
apm-integrations-kafkajs 67.26% <100.00%> (+0.03%) ⬆️
apm-integrations-next 63.90% <100.00%> (+0.04%) ⬆️
apm-integrations-prisma 61.94% <100.00%> (+0.04%) ⬆️
appsec 76.76% <100.00%> (+0.01%) ⬆️
appsec-express_fastify_graphql 72.70% <86.00%> (+<0.01%) ⬆️
appsec-integration 49.59% <86.41%> (+0.07%) ⬆️
appsec-kafka_ldapjs_lodash 67.49% <100.00%> (+<0.01%) ⬆️
appsec-mongodb-core_mongoose_mysql 70.67% <100.00%> (+0.02%) ⬆️
appsec-next 57.17% <100.00%> (+0.04%) ⬆️
appsec-node-serialize_passport_postgres 70.14% <100.00%> (+0.02%) ⬆️
appsec-sourcing_stripe_template 68.57% <100.00%> (+0.02%) ⬆️
debugger 69.11% <100.00%> (+0.04%) ⬆️
instrumentations-bucket-0 56.15% <100.00%> (+0.06%) ⬆️
instrumentations-bucket-1 64.22% <100.00%> (+0.04%) ⬆️
instrumentations-bucket-10 53.37% <100.00%> (+0.06%) ⬆️
instrumentations-bucket-11 65.67% <100.00%> (+0.03%) ⬆️
instrumentations-bucket-12 61.46% <100.00%> (+0.05%) ⬆️
instrumentations-bucket-13 56.35% <100.00%> (+0.06%) ⬆️
instrumentations-bucket-14 55.80% <100.00%> (+0.06%) ⬆️
instrumentations-bucket-2 56.99% <100.00%> (+0.05%) ⬆️
instrumentations-bucket-3 57.20% <100.00%> (+0.05%) ⬆️
instrumentations-bucket-4 63.84% <100.00%> (+0.04%) ⬆️
instrumentations-bucket-5 56.60% <100.00%> (+0.06%) ⬆️
instrumentations-bucket-6 58.17% <100.00%> (+0.04%) ⬆️
instrumentations-bucket-7 65.71% <100.00%> (+0.04%) ⬆️
instrumentations-bucket-8 62.98% <100.00%> (+0.04%) ⬆️
instrumentations-bucket-9 64.57% <100.00%> (+0.04%) ⬆️
instrumentations-instrumentation-couchbase 54.77% <100.00%> (+0.06%) ⬆️
instrumentations-instrumentation-zlib 55.84% <100.00%> (+0.06%) ⬆️
instrumentations-integration-esbuild 34.57% <100.00%> (+0.07%) ⬆️
llmobs-ai_anthropic_bedrock 66.73% <100.00%> (+0.03%) ⬆️
llmobs-bucket-1 64.89% <100.00%> (+0.03%) ⬆️
llmobs-openai 66.74% <100.00%> (+0.03%) ⬆️
llmobs-openai-agents_vertex-ai 64.03% <100.00%> (+0.03%) ⬆️
llmobs-sdk 75.94% <100.00%> (+0.02%) ⬆️
master-coverage 98.62% <100.00%> (?)
openfeature 59.66% <100.00%> (+0.07%) ⬆️
openfeature-unit 58.34% <100.00%> (+0.05%) ⬆️
platform-core_esbuild_instrumentations-misc 41.12% <100.00%> (+0.04%) ⬆️
platform-integration 64.86% <100.00%> (+0.05%) ⬆️
platform-shimmer_unit-guardrails_webpack 38.96% <100.00%> (+0.04%) ⬆️
plugins-browser-bunyan_bullmq_cassandra 66.28% <100.00%> (+0.03%) ⬆️
plugins-bucket-0 60.98% <100.00%> (+0.04%) ⬆️
plugins-bucket-1 58.22% <100.00%> (+0.08%) ⬆️
plugins-bucket-11 67.78% <90.53%> (+0.08%) ⬆️
plugins-bucket-18 65.41% <63.37%> (-0.04%) ⬇️
plugins-bucket-19 64.98% <100.00%> (+0.04%) ⬆️
plugins-bucket-20 68.80% <100.00%> (+0.14%) ⬆️
plugins-bucket-4 61.14% <100.00%> (+0.05%) ⬆️
plugins-cookie_cookie-parser_crypto 55.75% <100.00%> (+0.06%) ⬆️
plugins-fastify_fetch_fs 65.42% <100.00%> (+0.03%) ⬆️
plugins-generic-pool_google-cloud-pubsub_grpc 68.97% <100.00%> (+0.03%) ⬆️
plugins-handlebars_hapi_hono 63.65% <100.00%> (+0.04%) ⬆️
plugins-ioredis_knex_langgraph 61.66% <100.00%> (+0.04%) ⬆️
plugins-ldapjs_light-my-request_limitd-client 63.37% <100.00%> (+0.04%) ⬆️
plugins-lodash_mariadb_memcached 63.75% <100.00%> (+0.04%) ⬆️
plugins-moleculer_mongodb_mongodb-core 66.10% <100.00%> (+0.03%) ⬆️
plugins-mongoose_multer_mysql 63.95% <100.00%> (+0.04%) ⬆️
plugins-mysql2_nats_node-serialize 66.16% <100.00%> (+0.04%) ⬆️
plugins-opensearch_passport-http_pino 64.06% <100.00%> (+0.04%) ⬆️
plugins-postgres_process_pug 63.10% <100.00%> (+0.04%) ⬆️
plugins-redis_router_sequelize 66.66% <100.00%> (+0.03%) ⬆️
plugins-test-and-upstream-rhea_undici_url 66.01% <100.00%> (+0.03%) ⬆️
plugins-valkey_vm_winston 62.43% <100.00%> (+0.04%) ⬆️
plugins-ws 64.49% <100.00%> (+0.04%) ⬆️
profiling 66.24% <100.00%> (+0.03%) ⬆️
serverless-aws-sdk-aws-sdk 55.47% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-base-inject-field 55.32% <100.00%> (+0.06%) ⬆️
serverless-aws-sdk-bedrockruntime 58.32% <100.00%> (+0.05%) ⬆️
serverless-aws-sdk-client 60.11% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-dynamodb 59.19% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-eventbridge 57.67% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-kinesis 63.15% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-lambda 61.12% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-s3 59.24% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-serverless-peer-service 63.72% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-sns 64.04% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-sqs 64.49% <100.00%> (+0.03%) ⬆️
serverless-aws-sdk-stepfunctions 59.09% <100.00%> (+0.04%) ⬆️
serverless-aws-sdk-util 55.94% <100.00%> (+0.06%) ⬆️
serverless-bucket-0 57.85% <100.00%> (+0.08%) ⬆️
serverless-bucket-1 63.73% <100.00%> (+0.04%) ⬆️
test-optimization-cucumber 70.53% <100.00%> (+0.02%) ⬆️
test-optimization-cypress 64.77% <100.00%> (+0.07%) ⬆️
test-optimization-jest 72.21% <100.00%> (+0.15%) ⬆️
test-optimization-mocha 71.99% <100.00%> (+0.08%) ⬆️
test-optimization-playwright-playwright-atr 59.82% <100.00%> (-0.02%) ⬇️
test-optimization-playwright-playwright-efd 60.45% <100.00%> (-0.01%) ⬇️
test-optimization-playwright-playwright-final-status 60.07% <100.00%> (-0.01%) ⬇️
test-optimization-playwright-playwright-impacted-tests 60.18% <100.00%> (+0.08%) ⬆️
test-optimization-playwright-playwright-reporting 61.15% <100.00%> (-0.01%) ⬇️
test-optimization-playwright-playwright-test-management 61.23% <100.00%> (-0.01%) ⬇️
test-optimization-playwright-playwright-test-span 59.87% <100.00%> (+0.04%) ⬆️
test-optimization-selenium 58.89% <100.00%> (-0.04%) ⬇️
test-optimization-testopt 61.82% <100.00%> (+0.09%) ⬆️
test-optimization-vitest 72.69% <100.00%> (+0.08%) ⬆️
test-optimization-vitest-browser 58.73% <100.00%> (-0.01%) ⬇️
test-optimization-webdriverio 65.52% <100.00%> (+0.09%) ⬆️

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.

Collapsed non-JIT fields reused the first span without observing later resolver completion, so a sibling rejection left the shared span and resolve hook successful.
Reused collapsed resolver calls share one span, but the prior error tracking entered a new async context and observed every call. GraphQL already normalizes resolver failures, so record errors at that boundary and leave successful reused calls unchanged.

Only delayed non-JIT resolve hooks release their field before the execute hook. JIT and execute-only paths retain their existing hook order.
@BridgeAR
BridgeAR force-pushed the BridgeAR/2026-08-31-graphql-non-jit-resolver-errors branch from de27cf9 to 754c778 Compare September 1, 2026 09:09
@BridgeAR
BridgeAR marked this pull request as ready for review September 1, 2026 12:13
@BridgeAR
BridgeAR requested review from a team as code owners September 1, 2026 12:13
@BridgeAR
BridgeAR requested a review from bojbrook September 1, 2026 12:13
@BridgeAR
BridgeAR merged commit 42b2917 into master Sep 2, 2026
690 checks passed
@BridgeAR
BridgeAR deleted the BridgeAR/2026-08-31-graphql-non-jit-resolver-errors branch September 2, 2026 17:56
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Sep 3, 2026
dd-octo-sts Bot pushed a commit that referenced this pull request Sep 3, 2026
* fix(graphql): record reused resolver errors

Collapsed non-JIT fields reused the first span without observing later resolver completion, so a sibling rejection left the shared span and resolve hook successful.

* perf(graphql): move collapsed resolver error tracking off hot path

Reused collapsed resolver calls share one span, but the prior error tracking entered a new async context and observed every call. GraphQL already normalizes resolver failures, so record errors at that boundary and leave successful reused calls unchanged.

Only delayed non-JIT resolve hooks release their field before the execute hook. JIT and execute-only paths retain their existing hook order.
@dd-octo-sts dd-octo-sts Bot mentioned this pull request Sep 3, 2026
dd-octo-sts Bot pushed a commit that referenced this pull request Sep 3, 2026
* fix(graphql): record reused resolver errors

Collapsed non-JIT fields reused the first span without observing later resolver completion, so a sibling rejection left the shared span and resolve hook successful.

* perf(graphql): move collapsed resolver error tracking off hot path

Reused collapsed resolver calls share one span, but the prior error tracking entered a new async context and observed every call. GraphQL already normalizes resolver failures, so record errors at that boundary and leave successful reused calls unchanged.

Only delayed non-JIT resolve hooks release their field before the execute hook. JIT and execute-only paths retain their existing hook order.
BridgeAR added a commit that referenced this pull request Sep 4, 2026
* fix(graphql): record reused resolver errors

Collapsed non-JIT fields reused the first span without observing later resolver completion, so a sibling rejection left the shared span and resolve hook successful.

* perf(graphql): move collapsed resolver error tracking off hot path

Reused collapsed resolver calls share one span, but the prior error tracking entered a new async context and observed every call. GraphQL already normalizes resolver failures, so record errors at that boundary and leave successful reused calls unchanged.

Only delayed non-JIT resolve hooks release their field before the execute hook. JIT and execute-only paths retain their existing hook order.
BridgeAR added a commit that referenced this pull request Sep 4, 2026
* fix(graphql): record reused resolver errors

Collapsed non-JIT fields reused the first span without observing later resolver completion, so a sibling rejection left the shared span and resolve hook successful.

* perf(graphql): move collapsed resolver error tracking off hot path

Reused collapsed resolver calls share one span, but the prior error tracking entered a new async context and observed every call. GraphQL already normalizes resolver failures, so record errors at that boundary and leave successful reused calls unchanged.

Only delayed non-JIT resolve hooks release their field before the execute hook. JIT and execute-only paths retain their existing hook order.
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.

2 participants