Skip to content

Commit cd071d4

Browse files
release: on branch next (#3020)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to next, this PR will be updated. # Releases ## @apollo/composition@2.8.0 ### Minor Changes - Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](#2988)) ```graphql type Query { p: Parent! } type Parent @key(fields: "id") @context(name: "context") { id: ID! child: Child! prop: String! } type Child @key(fields: "id") { id: ID! b: String! field(a: String @fromcontext(field: "$context { prop }")): Int! } ``` ### Patch Changes - Various set context bugfixes ([#3017](#3017)) - Updated dependencies \[[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](c4744da), [`8a936d741a0c05835ff2533714cf330d18209179`](8a936d7), [`f5fe3e74d36722f78004c1e2e03c77d8b95cd6bf`](f5fe3e7)]: - @apollo/query-graphs@2.8.0 - @apollo/federation-internals@2.8.0 ## @apollo/gateway@2.8.0 ### Minor Changes - Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](#2988)) ```graphql type Query { p: Parent! } type Parent @key(fields: "id") @context(name: "context") { id: ID! child: Child! prop: String! } type Child @key(fields: "id") { id: ID! b: String! field(a: String @fromcontext(field: "$context { prop }")): Int! } ``` ### Patch Changes - Various set context bugfixes ([#3017](#3017)) - Updated dependencies \[[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](c4744da), [`8a936d741a0c05835ff2533714cf330d18209179`](8a936d7), [`daf36bd242ba4db0cfcf0e18c1eed235ff0dfaf2`](daf36bd)]: - @apollo/query-planner@2.8.0 - @apollo/composition@2.8.0 - @apollo/federation-internals@2.8.0 ## @apollo/federation-internals@2.8.0 ### Minor Changes - Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](#2988)) ```graphql type Query { p: Parent! } type Parent @key(fields: "id") @context(name: "context") { id: ID! child: Child! prop: String! } type Child @key(fields: "id") { id: ID! b: String! field(a: String @fromcontext(field: "$context { prop }")): Int! } ``` ### Patch Changes - Various set context bugfixes ([#3017](#3017)) ## @apollo/query-graphs@2.8.0 ### Minor Changes - Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](#2988)) ```graphql type Query { p: Parent! } type Parent @key(fields: "id") @context(name: "context") { id: ID! child: Child! prop: String! } type Child @key(fields: "id") { id: ID! b: String! field(a: String @fromcontext(field: "$context { prop }")): Int! } ``` ### Patch Changes - Various set context bugfixes ([#3017](#3017)) - Fix bug in context-matching logic for interfaces-implementing-interfaces (#3014) ([#3015](#3015)) A field is considered to match a context if the field's parent type (in the original query) either has `@context` on it, or implements/is a member of a type with `@context` on it. We ended up missing the case where interfaces implement interfaces; this PR introduces a fix. - Updated dependencies \[[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](c4744da), [`8a936d741a0c05835ff2533714cf330d18209179`](8a936d7)]: - @apollo/federation-internals@2.8.0 ## @apollo/query-planner@2.8.0 ### Minor Changes - Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](#2988)) ```graphql type Query { p: Parent! } type Parent @key(fields: "id") @context(name: "context") { id: ID! child: Child! prop: String! } type Child @key(fields: "id") { id: ID! b: String! field(a: String @fromcontext(field: "$context { prop }")): Int! } ``` ### Patch Changes - Various set context bugfixes ([#3017](#3017)) - Fix relative path logic when eliding subgraph jumps for `@fromContext` ([#3005](#3005)) - Updated dependencies \[[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](c4744da), [`8a936d741a0c05835ff2533714cf330d18209179`](8a936d7), [`f5fe3e74d36722f78004c1e2e03c77d8b95cd6bf`](f5fe3e7)]: - @apollo/query-graphs@2.8.0 - @apollo/federation-internals@2.8.0 ## @apollo/subgraph@2.8.0 ### Patch Changes - Various set context bugfixes ([#3017](#3017)) - Updated dependencies \[[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](c4744da), [`8a936d741a0c05835ff2533714cf330d18209179`](8a936d7)]: - @apollo/federation-internals@2.8.0 ## apollo-federation-integration-testsuite@2.8.0 ### Patch Changes - Various set context bugfixes ([#3017](#3017)) Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
1 parent 9324430 commit cd071d4

20 files changed

Lines changed: 199 additions & 98 deletions

File tree

.changeset/hungry-llamas-remember.md

Lines changed: 0 additions & 25 deletions
This file was deleted.

.changeset/popular-chairs-happen.md

Lines changed: 0 additions & 11 deletions
This file was deleted.

.changeset/pre.json

Lines changed: 0 additions & 18 deletions
This file was deleted.

.changeset/quick-zebras-wave.md

Lines changed: 0 additions & 7 deletions
This file was deleted.

.changeset/rare-grapes-dream.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

composition-js/CHANGELOG.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,35 @@
11
# CHANGELOG for `@apollo/composition`
22

3+
## 2.8.0
4+
5+
### Minor Changes
6+
7+
- Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](https://github.com/apollographql/federation/pull/2988))
8+
9+
```graphql
10+
type Query {
11+
p: Parent!
12+
}
13+
type Parent @key(fields: "id") @context(name: "context") {
14+
id: ID!
15+
child: Child!
16+
prop: String!
17+
}
18+
type Child @key(fields: "id") {
19+
id: ID!
20+
b: String!
21+
field(a: String @fromContext(field: "$context { prop }")): Int!
22+
}
23+
```
24+
25+
### Patch Changes
26+
27+
- Various set context bugfixes ([#3017](https://github.com/apollographql/federation/pull/3017))
28+
29+
- Updated dependencies [[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](https://github.com/apollographql/federation/commit/c4744da360235d8bb8270ea048f0e0fa5d03be1e), [`8a936d741a0c05835ff2533714cf330d18209179`](https://github.com/apollographql/federation/commit/8a936d741a0c05835ff2533714cf330d18209179), [`f5fe3e74d36722f78004c1e2e03c77d8b95cd6bf`](https://github.com/apollographql/federation/commit/f5fe3e74d36722f78004c1e2e03c77d8b95cd6bf)]:
30+
- @apollo/query-graphs@2.8.0
31+
- @apollo/federation-internals@2.8.0
32+
333
## 2.8.0-alpha.1
434

535
### Patch Changes

composition-js/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@apollo/composition",
3-
"version": "2.8.0-alpha.1",
3+
"version": "2.8.0",
44
"description": "Apollo Federation composition utilities",
55
"main": "dist/index.js",
66
"types": "dist/index.d.ts",
@@ -27,8 +27,8 @@
2727
"access": "public"
2828
},
2929
"dependencies": {
30-
"@apollo/federation-internals": "2.8.0-alpha.1",
31-
"@apollo/query-graphs": "2.8.0-alpha.1"
30+
"@apollo/federation-internals": "2.8.0",
31+
"@apollo/query-graphs": "2.8.0"
3232
},
3333
"peerDependencies": {
3434
"graphql": "^16.5.0"

federation-integration-testsuite-js/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# CHANGELOG for `federation-integration-testsuite-js`
22

3+
## 2.8.0
4+
5+
### Patch Changes
6+
7+
- Various set context bugfixes ([#3017](https://github.com/apollographql/federation/pull/3017))
8+
39
## 2.8.0-alpha.1
410

511
## 2.8.0-alpha.0

federation-integration-testsuite-js/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "apollo-federation-integration-testsuite",
33
"private": true,
4-
"version": "2.8.0-alpha.1",
4+
"version": "2.8.0",
55
"description": "Apollo Federation Integrations / Test Fixtures",
66
"main": "dist/index.js",
77
"types": "dist/index.d.ts",

gateway-js/CHANGELOG.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,36 @@
11
# CHANGELOG for `@apollo/gateway`
22

3+
## 2.8.0
4+
5+
### Minor Changes
6+
7+
- Implement new directives to allow getting and setting context. This allows resolvers to reference and access data referenced by entities that exist in the GraphPath that was used to access the field. The following example demonstrates the ability to access the `prop` field within the Child resolver. ([#2988](https://github.com/apollographql/federation/pull/2988))
8+
9+
```graphql
10+
type Query {
11+
p: Parent!
12+
}
13+
type Parent @key(fields: "id") @context(name: "context") {
14+
id: ID!
15+
child: Child!
16+
prop: String!
17+
}
18+
type Child @key(fields: "id") {
19+
id: ID!
20+
b: String!
21+
field(a: String @fromContext(field: "$context { prop }")): Int!
22+
}
23+
```
24+
25+
### Patch Changes
26+
27+
- Various set context bugfixes ([#3017](https://github.com/apollographql/federation/pull/3017))
28+
29+
- Updated dependencies [[`c4744da360235d8bb8270ea048f0e0fa5d03be1e`](https://github.com/apollographql/federation/commit/c4744da360235d8bb8270ea048f0e0fa5d03be1e), [`8a936d741a0c05835ff2533714cf330d18209179`](https://github.com/apollographql/federation/commit/8a936d741a0c05835ff2533714cf330d18209179), [`daf36bd242ba4db0cfcf0e18c1eed235ff0dfaf2`](https://github.com/apollographql/federation/commit/daf36bd242ba4db0cfcf0e18c1eed235ff0dfaf2)]:
30+
- @apollo/query-planner@2.8.0
31+
- @apollo/composition@2.8.0
32+
- @apollo/federation-internals@2.8.0
33+
334
## 2.8.0-alpha.1
435

536
### Patch Changes

0 commit comments

Comments
 (0)