Conversation
Contributor
|
|
❌ ErrorsYour PR has failed checks. Please review the issues below and take necessary action before merging. 🚦 267 Pipeline jobs failed ℹ️ InfoNo other issues found (see more)🧪 All tests passed Useful? React with 👍 / 👎 This comment will be updated automatically if new data arrives.🔗 Commit SHA: c73a29a | Docs | View more details | Give us feedback! |
CarlesDD
force-pushed
the
ccapell/APPSEC-70386/nodejs-thread-context-sharing-endpoint
branch
from
October 1, 2026 07:19
803f358 to
a672525
Compare
CarlesDD
force-pushed
the
ccapell/APPSEC-70386/nodejs-thread-context-sharing-endpoint
branch
from
October 1, 2026 13:33
2a1dd35 to
7ecdfaf
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
Node.js has no
/security/thread_context_sharingendpoint yet, soTest_ThreadContextSharing(THREAD_CONTEXT_SHARINGscenario) cannot run for Node.js.Changes
GET /security/thread_context_sharingin:express/app.js(shared byexpress4,uds-express4,express5)fastify/app.jsexpress4-typescript/app.tsnextjs(new App Router routesrc/app/security/thread_context_sharing/route.js)nextjs.Dockerfile: copy the newsrc/app/securityroute so no base image rebuild is needed.pathwithfs.writeFileSync. Asyncfswould open the file on a libuv worker thread, which does not carry the request's thread context that system-probe reads. It returns the active span's 128-bit trace ID and span ID as decimal strings, and returns400whenpathis missing.manifests/nodejs.yml: keepTest_ThreadContextSharingasmissing_feature, updating the reason tothread context sharing not enabled for appsec yet. The endpoint now exists, but dd-trace-js only publishes the thread context whenDD_TRACE_OTEL_CTX_ENABLED=true, and this scenario only setsDD_APPSEC_ENABLED=true.Activation is intentionally left for a follow-up. It also needs a Node.js weblog with AsyncContextFrame active (Node.js 24+): all Node.js weblogs currently run Node.js 18–22, and
express5, the only one scheduled for this scenario, runsnode:18-alpine.Workflow
system-tests-reviewers: ask to one of youre co-worker familiar with the tested feature.system-tests-core(slack)🚀 Once your PR is reviewed and the CI green, you can merge it!
🛟 #apm-shared-testing 🛟