[TT-17578] Bump graphql-go-tools to fix Federation subscription-then-query null regression#8345
Conversation
Picks up TykTechnologies/graphql-go-tools#447, which stops the original websocket request context (including the "this request is a websocket upgrade" flag) from leaking into the engine's upstream/subgraph fetches. This fixes the regression where starting a GraphQL Federation subscription caused subsequent queries run over the websocket connection to return null data. Bumps the v1 module only; the gateway's graphql-go-tools/v2 pin predates TT-17442 and is not affected by this regression.
🎯 Recommended Merge TargetsBased on JIRA ticket TT-17578: Starting a subscription on a Federation API breaks subsequent queries Fix Version: Tyk 5.8.15Required:
📋 Workflow
|
|
This PR bumps the Files Changed AnalysisThe changes are confined to Go module files, confirming this is a dependency update with no direct code modifications in this repository:
Architecture & Impact Assessment
Bug vs. Fix FlowThe following diagram illustrates how context leakage caused the failure and how the dependency update resolves it. sequenceDiagram
participant Client
participant Tyk Gateway
participant Subgraph
note over Client, Subgraph: Old Behavior (Bug)
rect rgb(255, 230, 230)
Client->>+Tyk Gateway: 1. Subscription (WebSocket Upgrade)
note right of Tyk Gateway: Context tagged: `isWebSocketUpgrade=true`
Tyk Gateway-->>-Client: Subscription OK
Client->>+Tyk Gateway: 2. Query (same connection)
Tyk Gateway->>+Subgraph: 3. HTTP request with leaked context
note right of Subgraph: Subgraph sees upgrade flag, fails HTTP request
Subgraph-->>-Tyk Gateway: 4. Error
Tyk Gateway-->>-Client: 5. `null` data
end
note over Client, Subgraph: New Behavior (Fix)
rect rgb(230, 255, 230)
Client->>+Tyk Gateway: 1. Subscription (WebSocket Upgrade)
Tyk Gateway-->>-Client: Subscription OK
Client->>+Tyk Gateway: 2. Query (same connection)
Tyk Gateway->>+Subgraph: 3. HTTP request with clean context
note right of Subgraph: Subgraph processes standard HTTP request
Subgraph-->>-Tyk Gateway: 4. Query Data
Tyk Gateway-->>-Client: 5. Correct data
end
Scope Discovery & Context ExpansionThe scope is narrow and well-defined. As stated in the PR description, the fix only applies to the Metadata
Powered by Visor from Probelabs Last updated: 2026-06-24T14:26:52.599Z | Triggered by: pr_updated | Commit: 4ec40ce 💡 TIP: You can chat with Visor using |
✅ Security Check PassedNo security issues found – changes LGTM. ✅ Architecture Check PassedNo architecture issues found – changes LGTM. ✅ Performance Check PassedNo performance issues found – changes LGTM. Powered by Visor from Probelabs Last updated: 2026-06-24T14:26:38.658Z | Triggered by: pr_updated | Commit: 4ec40ce 💡 TIP: You can chat with Visor using |
graphql-go-tools#447 is merged to master; pin to that master commit (dae0d8d8) which stops the original websocket request context (including the "this request is a websocket upgrade" flag) from leaking into the engine's upstream/subgraph fetches. Fixes the regression where a GraphQL Federation subscription caused subsequent queries over the websocket connection to return null. v1 module only; the gateway's graphql-go-tools/v2 pin predates TT-17442 and is not affected.
f0de864 to
ba10993
Compare
|
SentinelOne CNS Hardcoded Secret Detector SentinelOne CNS is a cloud-agnostic, agentless CSPM & CWPP solution that continuously detects and prevents vulnerabilities that have the highest probability of being exploited in Azure, AWS, Google Cloud, and Kubernetes. |
🚨 Jira Linter FailedCommit: The Jira linter failed to validate your PR. Please check the error details below: 🔍 Click to view error detailsNext Steps
This comment will be automatically deleted once the linter passes. |
|
|
/release to release-5.8 |
|
|
…query null regression (#8345) Bumps `github.com/TykTechnologies/graphql-go-tools` to pick up **TykTechnologies/graphql-go-tools#447**. On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return `null` instead of data. Gateway logs show `websocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' header` against the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0). The gateway tags an inbound websocket subscription request with a context value `GraphQLIsWebSocketUpgrade=true`. The library change in `mergedContext` that resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed → `null`. The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests. - Bumps the **v1** module only (`v1.6.2-0.20260610093432-c7048b604e16` → `v1.6.2-0.20260623130956-98d2c88fce43`). - The gateway's `graphql-go-tools/v2` pin predates TT-17442, so the v3/v2 engine path is **not** affected and is intentionally left unchanged. - `go mod verify` passes; `internal/graphengine` and `apidef/adapter/...` build against the new pin. > Draft — depends on graphql-go-tools#447, which is not merged yet. The version pin points at the #447 branch commit and must be re-pinned to the squash-merge commit once #447 lands. [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ (cherry picked from commit 63316b3)
|
/release to release-5.8.15 |
|
|
…query null regression (#8345) Bumps `github.com/TykTechnologies/graphql-go-tools` to pick up **TykTechnologies/graphql-go-tools#447**. On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return `null` instead of data. Gateway logs show `websocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' header` against the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0). The gateway tags an inbound websocket subscription request with a context value `GraphQLIsWebSocketUpgrade=true`. The library change in `mergedContext` that resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed → `null`. The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests. - Bumps the **v1** module only (`v1.6.2-0.20260610093432-c7048b604e16` → `v1.6.2-0.20260623130956-98d2c88fce43`). - The gateway's `graphql-go-tools/v2` pin predates TT-17442, so the v3/v2 engine path is **not** affected and is intentionally left unchanged. - `go mod verify` passes; `internal/graphengine` and `apidef/adapter/...` build against the new pin. > Draft — depends on graphql-go-tools#447, which is not merged yet. The version pin points at the #447 branch commit and must be re-pinned to the squash-merge commit once #447 lands. [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ (cherry picked from commit 63316b3)
|
/release to release-5.13 |
|
/release to release-5.13.1 |
|
/release to release-5.14 |
|
✅ Cherry-pick successful. A PR was created: #8359 |
|
✅ Cherry-pick successful. A PR was created: #8360 |
|
/release to release-5.14.1 |
|
✅ Cherry-pick successful. A PR was created: #8361 |
|
❌ Cherry-pick failed. Please check the workflow logs. |
|
/release to release-5.14.0 |
|
✅ Cherry-pick successful. A PR was created: #8362 |
…ation subscription-then-query null regression (#8345) (#8357) Cherry-pick of `63316b393a9849620dece3e7b6447f2fe066dbe2` from `master` to `release-5.8` requires manual resolution. **Conflicts detected:** 3 - go.sum Tips: - Check out this branch locally and run: `git cherry-pick -x 63316b3` - Resolve conflicts (including submodules if any), then push back to this branch. Original commit: 63316b3 --------- Co-authored-by: Tyk Bot <[email protected]> Co-authored-by: Matias <[email protected]>
…deration subscription-then-query null regression (#8345) (#8362) [TT-17578] Bump graphql-go-tools to fix Federation subscription-then-query null regression (#8345) ## Description Bumps `github.com/TykTechnologies/graphql-go-tools` to pick up **TykTechnologies/graphql-go-tools#447**. ### The bug On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return `null` instead of data. Gateway logs show `websocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' header` against the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0). ### Root cause The gateway tags an inbound websocket subscription request with a context value `GraphQLIsWebSocketUpgrade=true`. The library change in #446 ([TT-17442]) wrapped the subscription executor's context in a `mergedContext` that resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed → `null`. ### The fix (library #447) The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests. ## Scope - Bumps the **v1** module only (`v1.6.2-0.20260610093432-c7048b604e16` → `v1.6.2-0.20260623130956-98d2c88fce43`). - The gateway's `graphql-go-tools/v2` pin predates TT-17442, so the v3/v2 engine path is **not** affected and is intentionally left unchanged. ## Verification - `go mod verify` passes; `internal/graphengine` and `apidef/adapter/...` build against the new pin. > Draft — depends on graphql-go-tools#447, which is not merged yet. The version pin points at the #447 branch commit and must be re-pinned to the squash-merge commit once #447 lands. [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17578]: https://tyktech.atlassian.net/browse/TT-17578?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ Co-authored-by: Matias <[email protected]>
…ration subscription-then-query null regression (#8345) (#8361) [TT-17578] Bump graphql-go-tools to fix Federation subscription-then-query null regression (#8345) ## Description Bumps `github.com/TykTechnologies/graphql-go-tools` to pick up **TykTechnologies/graphql-go-tools#447**. ### The bug On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return `null` instead of data. Gateway logs show `websocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' header` against the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0). ### Root cause The gateway tags an inbound websocket subscription request with a context value `GraphQLIsWebSocketUpgrade=true`. The library change in #446 ([TT-17442]) wrapped the subscription executor's context in a `mergedContext` that resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed → `null`. ### The fix (library #447) The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests. ## Scope - Bumps the **v1** module only (`v1.6.2-0.20260610093432-c7048b604e16` → `v1.6.2-0.20260623130956-98d2c88fce43`). - The gateway's `graphql-go-tools/v2` pin predates TT-17442, so the v3/v2 engine path is **not** affected and is intentionally left unchanged. ## Verification - `go mod verify` passes; `internal/graphengine` and `apidef/adapter/...` build against the new pin. > Draft — depends on graphql-go-tools#447, which is not merged yet. The version pin points at the #447 branch commit and must be re-pinned to the squash-merge commit once #447 lands. [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17578]: https://tyktech.atlassian.net/browse/TT-17578?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ Co-authored-by: Matias <[email protected]>
…deration subscription-then-query null regression (#8345) (#8360) [TT-17578] Bump graphql-go-tools to fix Federation subscription-then-query null regression (#8345) ## Description Bumps `github.com/TykTechnologies/graphql-go-tools` to pick up **TykTechnologies/graphql-go-tools#447**. ### The bug On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return `null` instead of data. Gateway logs show `websocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' header` against the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0). ### Root cause The gateway tags an inbound websocket subscription request with a context value `GraphQLIsWebSocketUpgrade=true`. The library change in #446 ([TT-17442]) wrapped the subscription executor's context in a `mergedContext` that resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed → `null`. ### The fix (library #447) The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests. ## Scope - Bumps the **v1** module only (`v1.6.2-0.20260610093432-c7048b604e16` → `v1.6.2-0.20260623130956-98d2c88fce43`). - The gateway's `graphql-go-tools/v2` pin predates TT-17442, so the v3/v2 engine path is **not** affected and is intentionally left unchanged. ## Verification - `go mod verify` passes; `internal/graphengine` and `apidef/adapter/...` build against the new pin. > Draft — depends on graphql-go-tools#447, which is not merged yet. The version pin points at the #447 branch commit and must be re-pinned to the squash-merge commit once #447 lands. [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17578]: https://tyktech.atlassian.net/browse/TT-17578?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ Co-authored-by: Matias <[email protected]>
…deration subscription-then-query null regression (#8345) (#8358) Cherry-pick of `63316b393a9849620dece3e7b6447f2fe066dbe2` from `master` to `release-5.8.15` requires manual resolution. **Conflicts detected:** 3 - go.sum Tips: - Check out this branch locally and run: `git cherry-pick -x 63316b3` - Resolve conflicts (including submodules if any), then push back to this branch. Original commit: 63316b3 --------- Co-authored-by: Tyk Bot <[email protected]> Co-authored-by: Matias <[email protected]> Co-authored-by: Matias <[email protected]>
…ration subscription-then-query null regression (#8345) (#8359) [TT-17578] Bump graphql-go-tools to fix Federation subscription-then-query null regression (#8345) ## Description Bumps `github.com/TykTechnologies/graphql-go-tools` to pick up **TykTechnologies/graphql-go-tools#447**. ### The bug On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return `null` instead of data. Gateway logs show `websocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' header` against the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0). ### Root cause The gateway tags an inbound websocket subscription request with a context value `GraphQLIsWebSocketUpgrade=true`. The library change in #446 ([TT-17442]) wrapped the subscription executor's context in a `mergedContext` that resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed → `null`. ### The fix (library #447) The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests. ## Scope - Bumps the **v1** module only (`v1.6.2-0.20260610093432-c7048b604e16` → `v1.6.2-0.20260623130956-98d2c88fce43`). - The gateway's `graphql-go-tools/v2` pin predates TT-17442, so the v3/v2 engine path is **not** affected and is intentionally left unchanged. ## Verification - `go mod verify` passes; `internal/graphengine` and `apidef/adapter/...` build against the new pin. > Draft — depends on graphql-go-tools#447, which is not merged yet. The version pin points at the #447 branch commit and must be re-pinned to the squash-merge commit once #447 lands. [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17578]: https://tyktech.atlassian.net/browse/TT-17578?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ [TT-17442]: https://tyktech.atlassian.net/browse/TT-17442?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ Co-authored-by: Matias <[email protected]>



Description
Bumps
github.com/TykTechnologies/graphql-go-toolsto pick up TykTechnologies/graphql-go-tools#447.The bug
On a GraphQL Federation supergraph API, running a subscription (websocket) first and then a query over the same connection makes the query return
nullinstead of data. Gateway logs showwebsocket upgrade for GraphQL engine failed: 'upgrade' token not found in 'Connection' headeragainst the subgraphs. Regression introduced in 5.8.15 / 5.13.1 / 5.14.0 (clean on 5.8.14 and 5.13.0).Root cause
The gateway tags an inbound websocket subscription request with a context value
GraphQLIsWebSocketUpgrade=true. The library change in #446 (TT-17442) wrapped the subscription executor's context in amergedContextthat resolved values from that original request context, so the flag leaked into every subgraph fetch. The subgraphs then tried to perform a websocket handshake on plain HTTP fetches, which failed →null.The fix (library #447)
The executor now builds its execution context without inheriting the original request's context values, while still forwarding the per-request header modifier — preserving TT-17442's per-user connection/credential isolation. See #447 for details and tests.
Scope
v1.6.2-0.20260610093432-c7048b604e16→v1.6.2-0.20260623130956-98d2c88fce43).graphql-go-tools/v2pin predates TT-17442, so the v3/v2 engine path is not affected and is intentionally left unchanged.Verification
go mod verifypasses;internal/graphengineandapidef/adapter/...build against the new pin.