-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cleanup
@graphql-tools/federation
(#308)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
- Loading branch information
1 parent
261d057
commit d747d4c
Showing
21 changed files
with
344 additions
and
1,245 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
'@graphql-tools/federation': patch | ||
--- | ||
|
||
dependencies updates: | ||
|
||
- Added dependency [`@graphql-yoga/typed-event-target@^3.0.0` ↗︎](https://www.npmjs.com/package/@graphql-yoga/typed-event-target/v/3.0.0) (to `dependencies`) | ||
- Added dependency [`@whatwg-node/disposablestack@^0.0.5` ↗︎](https://www.npmjs.com/package/@whatwg-node/disposablestack/v/0.0.5) (to `dependencies`) | ||
- Added dependency [`@whatwg-node/events@^0.1.2` ↗︎](https://www.npmjs.com/package/@whatwg-node/events/v/0.1.2) (to `dependencies`) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
'@graphql-tools/federation': major | ||
--- | ||
|
||
BREAKING CHANGES; | ||
|
||
- Removed `buildSubgraphSchema`, use `@apollo/subgraph` instead. | ||
- Removed the following gateway related functions, and prefer using Supergraph approach instead | ||
- `getSubschemaForFederationWithURL` | ||
- `getSubschemaForFederationWithTypeDefs` | ||
- `getSubschemaForFederationWithExecutor` | ||
- `getSubschemaForFederationWithSchema` | ||
- `federationSubschemaTransformer` | ||
- `SupergraphSchemaManager` is no longer an `EventEmitter` but `EventTarget` instead, and it emits a real `Event` object. | ||
- `SupergraphSchemaManager` is now `Disposable` and it no longer stops based on Nodejs terminate events, so you should use `using` syntax. | ||
|
||
```ts | ||
using manager = new SupergraphSchemaManager({ ... }); | ||
|
||
manager.addEventListener('error', (event: SupergraphSchemaManagerErrorEvent) => { | ||
console.error(event.detail.error); | ||
}); | ||
|
||
let schema: GraphQLSchema | null = null; | ||
manager.addEventListener('schema', (event: SupergraphSchemaManagerSchemaEvent) => { | ||
schema = event.detail.schema; | ||
}); | ||
``` |
This file contains 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
This file contains 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
This file was deleted.
Oops, something went wrong.
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
export * from './gateway.js'; | ||
export * from './managed-federation.js'; | ||
export * from './subgraph.js'; | ||
export * from './supergraph.js'; | ||
export * from './utils.js'; |
Oops, something went wrong.