Releases: apollographql/apollo-server
@apollo/[email protected]
Patch Changes
- Updated dependencies [
ebfde0007
]:- @apollo/[email protected]
@apollo/[email protected]
Minor Changes
-
#7617
4ff81ca50
Thanks @trevor-scheer! - Introduce newApolloServerPluginSubscriptionCallback
plugin. This plugin implements the subscription callback protocol which is used by Apollo Router. This feature implements subscriptions over HTTP via a callback URL which Apollo Router registers with Apollo Server. This feature is currently in preview and is subject to change.You can enable callback subscriptions like so:
import { ApolloServerPluginSubscriptionCallback } from '@apollo/server/plugin/subscriptionCallback'; import { ApolloServer } from '@apollo/server'; const server = new ApolloServer({ // ... plugins: [ApolloServerPluginSubscriptionCallback()], });
Note that there is currently no tracing or metrics mechanism in place for callback subscriptions. Additionally, this plugin "intercepts" callback subscription requests and bypasses some of Apollo Server's internals. The result of this is that certain plugin hooks (notably
executionDidStart
andwillResolveField
) will not be called when handling callback subscription requests or when sending subscription events.For more information on the subscription callback protocol, visit the docs:
https://www.apollographql.com/docs/router/executing-operations/subscription-callback-protocol/
Patch Changes
@apollo/[email protected]
@apollo/[email protected]
Patch Changes
- #7636
42fc65cb2
Thanks @trevor-scheer! - Update test suite for compatibility with Node v20
@apollo/[email protected]
Patch Changes
-
#7636
42fc65cb2
Thanks @trevor-scheer! - Update test suite for compatibility with Node v20 -
Updated dependencies [
42fc65cb2
]:- @apollo/[email protected]
@apollo/[email protected]
Minor Changes
-
#7634
f8a8ea08f
Thanks @dfperry5! - Updating the ApolloServer constructor to take in a stringifyResult function that will allow a consumer to pass in a function that formats the result of an http query.Usage:
const server = new ApolloServer({ typeDefs, resolvers, stringifyResult: (value: FormattedExecutionResult) => { return JSON.stringify(value, null, 2); }, });
@apollo/[email protected]
@apollo/[email protected]
Patch Changes
@apollo/[email protected]
Patch Changes
-
#7614
4fadf3ddc
Thanks @Cellule! - Publish TypeScript typings for CommonJS modules output.This allows TypeScript projects that use CommonJS modules with
moduleResolution: "node16"
or
moduleResolution: "nodeNext"
to correctly resolves the typings of apollo's packages as CommonJS instead of ESM. -
Updated dependencies [
4fadf3ddc
]:- @apollo/[email protected]
- @apollo/[email protected]
- @apollo/[email protected]