@graphql-yoga/plugin-apollo-usage-report
Changelog for @graphql-yoga/plugin-apollo-usage-report: every release with its changes and the pull requests behind them.
1.0.0
Major Changes
-
#4623
be89d05Thanks @ardatan! - ### Dependencies- Bump
@graphql-tools/utilsto^13.1.1,@graphql-tools/schemato^11.0.0, and@graphql-tools/executorto^4.1.2.
Incremental delivery
Yoga maps the GraphQL HTTP
Acceptheader throughINCREMENTAL_DELIVERY_SPECSfrom@graphql-tools/utilsonto executorincrementalSpec.multipart/mixed;incrementalSpec=v0.2runs the v0.2 payload format and echoes that spec onContent-Type.multipart/mixed;deferSpec=20220824or baremultipart/mixedstays on v0.1. An unsupported incremental spec yields 406.A later incremental spec is a graphql-tools table row plus an executor publisher. Yoga, Hive Gateway, and HTTP executors pick it up by bumping
@graphql-tools/utils/@graphql-tools/executor.Breaking Changes
createGraphQLErroris removed. Usenew GraphQLError(message, options)fromgraphql. To attach Yoga’s experimental schema coordinate, usewithSchemaCoordinate(error, coordinate)and read withgetSchemaCoordinatefrom@graphql-tools/utils.mapMaybePromiseis removed (was exported from Yoga /@envelop/core). UsehandleMaybePromisefrom@whatwg-node/promise-helpers.- Yoga no longer re-exports helpers that already live upstream:
getSchemaCoordinate->@graphql-tools/utilsmergeSchemas->@graphql-tools/schemaDisposableSymbols->@whatwg-node/servermapAsyncIterator/isPromise/fakePromise/handleMaybePromise/MaybePromise->@whatwg-node/promise-helpers
@envelop/coreutilsno longer re-exportsmapAsyncIteratororisPromise. Import from@whatwg-node/promise-helpers.- Use
asGetArgumentValuesVariables/coerceGetVariableValuesResultfrom@graphql-tools/utilsfor GraphQL 16/17VariableValuescompatibility.
Migration
import { GraphQLError } from 'graphql' import { withSchemaCoordinate } from 'graphql-yoga' import { mergeSchemas } from '@graphql-tools/schema' import { getSchemaCoordinate } from '@graphql-tools/utils' import { handleMaybePromise, isPromise, type MaybePromise } from '@whatwg-node/promise-helpers' import { DisposableSymbols } from '@whatwg-node/server' throw withSchemaCoordinate(new GraphQLError('not found'), 'Query.user') - Bump
Minor Changes
-
#4574
79b0e8bThanks @egoodwinx! - ### Breaking Changes- Node: minimum supported version is now Node 22. Node 18 and 20 are no longer supported. Future releases will only support Node >=22.
- GraphQL: minimum supported version is now GraphQL 16. GraphQL 14 and 15 are no longer supported.
- Request body parsing: Yoga now limits request bodies to 25,000,000 bytes by default.
Enforcing this limit streams the body through a byte counter, making POST body parsing
asynchronous even for an in-memory body. As a result,
yoga.fetch()can return a Promise where it previously returned a synchronous Response, even when all resolvers and plugins are synchronous.
Migration
- If you’re on Node 18/20, upgrade to Node 22 or later before upgrading this package.
- If you’re on graphql 14/15, upgrade to graphql 16 or 17 first.
- Await
yoga.fetch()and response body parsing instead of relying on synchronous results. SetmaxRequestBodySize: falseincreateYogato disable the body-size limit and preserve synchronous parsing for in-memory bodies, but only if you enforce an appropriate request-body limit elsewhere.
Patch Changes
-
#4575
862447aThanks @egoodwinx! - Use@graphql-hive/loggerand add correlated, per-request logging (closes #4048)Every request now gets its own logger, available as
context.log(andserverContext.login plugin hooks), tagged with arequestId. Everything logged while handling a request can be correlated by that id.The request id is taken from the host integration if it already assigned one (e.g. Fastify’s
request.id), otherwise from the incomingx-request-idheader, otherwise generated. It is also sent back in thex-request-idresponse header. Configure it with the newrequestIdoption:createYoga({ requestId: { // don't trust the incoming header, recommended when clients can reach the server directly trustHeader: false, headerName: 'x-correlation-id', generateRequestId: () => myId() } })Pass
requestId: falseto disable it.At the
infolevel, a single “Request processed” line is logged per request with the method, path, operation name and type, response status, error count and duration. At thedebuglevel, more details about request processing are logged.Masked errors are now logged with the request’s logger, so they can be traced back to the request that caused them. Custom
maskErrorfunctions receive the request’s context as an optional fourth argument.The
@envelop/newrelic,@envelop/auth0,@envelop/resource-limitations,@envelop/statsd,@envelop/graphql-jit,@envelop/response-cacheand@envelop/response-cache-cloudflare-kvplugins accept a newlogoption for their own messages, instead of always writing to the console.@envelop/response-cache’sshouldCacheResultnow also receives the GraphQLcontext.Breaking Changes
- The
@graphql-yoga/loggerpackage has been removed.graphql-yogare-exportsLogger,MemoryLogWriterandLogLevelfrom@graphql-hive/loggerinstead. createLoggerand theYogaLoggertype are no longer exported. Usenew Logger(options)instead.- The
loggingoption now takesboolean | Logger | LogLevel, whereLoggeris the one from@graphql-hive/logger. yoga.loggerhas been renamed toyoga.log.- The
loggeroption ofuseGraphiQLanduseHealthCheckhas been removed. They now log through the request’s logger. @graphql-yoga/nestjsnow logs through Nest’sLoggerby default instead of not logging at all. Passlogging: falseto keep the previous behaviour.logging: trueon Fastify no longer logs through Fastify’s logger, pass it explicitly instead (see below).@envelop/apollo-federation,@envelop/auth0,@envelop/graphql-jit,@envelop/newrelic,@envelop/resource-limitations,@envelop/response-cache,@envelop/response-cache-cloudflare-kvand@envelop/statsdnow have a peer dependency on@graphql-hive/loggerthat you must install.@envelop/apollo-federation’sloggeroption now expects aLoggerfrom@graphql-hive/loggerand defaults tonew Logger()instead ofconsole.
Migration
Create loggers with
Logger:- import { createLogger } from 'graphql-yoga'; + import { Logger } from 'graphql-yoga'; createYoga({ - logging: createLogger('debug'), + logging: new Logger({ level: 'debug' }), });Use
loginstead ofloggeron the Yoga instance:const plugin = { onYogaInit({ yoga }) { - yoga.logger.info('ready'); + yoga.log.info('ready'); }, };Prefer the request-scoped logger inside resolvers and plugin hooks so the logs carry the request id:
const resolvers = { Query: { hello: (_, __, context) => { context.log.debug('resolving hello') return 'world' } } }If you use any of the
@envelop/*plugins listed above, install the logger:npm i @graphql-hive/loggerIf you depended on
@graphql-yoga/loggerdirectly, switch to@graphql-hive/logger:- import { Logger } from '@graphql-yoga/logger'; + import { Logger } from '@graphql-hive/logger';To keep logging through Fastify’s logger in
@graphql-yoga/nestjs:import { Logger } from 'graphql-yoga' import { PinoLogWriter } from '@graphql-hive/logger/writers/pino' // in your yoga driver options logging: new Logger({ writers: [new PinoLogWriter(app.log)] }) - The
-
Updated dependencies [
862447a,79b0e8b,be89d05,5334079,79b0e8b]:- graphql-yoga@6.0.0
- @graphql-yoga/plugin-apollo-inline-trace@4.0.0
0.19.6
Patch Changes
- Updated dependencies
[
9294289]:- graphql-yoga@5.24.6
- @graphql-yoga/plugin-apollo-inline-trace@3.24.6
0.19.5
Patch Changes
- Updated dependencies []:
- graphql-yoga@5.24.5
- @graphql-yoga/plugin-apollo-inline-trace@3.24.5
0.19.4
Patch Changes
- #4607
d8b8860Thanks @enisdenjo! - dependencies updates:- Updated dependency
@graphql-tools/utils@^12.0.3↗︎ (from^11.2.2, independencies)
- Updated dependency
- Updated dependencies
[
d8b8860]:- graphql-yoga@5.24.4
- @graphql-yoga/plugin-apollo-inline-trace@3.24.4
0.19.3
Patch Changes
- #4604
c6febdcThanks @enisdenjo! - dependencies updates:- Updated dependency
@graphql-tools/utils@^11.2.2↗︎ (from^11.2.0, independencies)
- Updated dependency
- Updated dependencies
[
c6febdc]:- graphql-yoga@5.24.3
- @graphql-yoga/plugin-apollo-inline-trace@3.24.3
0.19.2
Patch Changes
- Updated dependencies
[
c08efde]:- graphql-yoga@5.24.2
- @graphql-yoga/plugin-apollo-inline-trace@3.24.2
0.19.1
Patch Changes
- Updated dependencies
[
c6a9aa4]:- graphql-yoga@5.24.1
- @graphql-yoga/plugin-apollo-inline-trace@3.24.1
0.19.0
Patch Changes
-
#4577
7bff35cThanks @egoodwinx! - Add homepage and bugs.url to package.json files -
Updated dependencies [
7bff35c,3763aca]:- @graphql-yoga/plugin-apollo-inline-trace@3.24.0
- graphql-yoga@5.24.0
0.18.0
Patch Changes
- Updated dependencies
[
c80f43c,d3b4164]:- graphql-yoga@5.23.0
- @graphql-yoga/plugin-apollo-inline-trace@3.23.0
0.17.0
Minor Changes
-
#4545
94ebe5bThanks @egoodwinx! - Update to support graphql-js 17Bump package versions, fix expected typing, and update compatability with subscribe.
Patch Changes
- Updated dependencies
[
94ebe5b]:- @graphql-yoga/plugin-apollo-inline-trace@3.22.0
- graphql-yoga@5.22.0
0.16.3
Patch Changes
- Updated dependencies
[
04014d2]:- graphql-yoga@5.21.3
- @graphql-yoga/plugin-apollo-inline-trace@3.21.3
0.16.2
Patch Changes
- Updated dependencies
[
39b55ba]:- graphql-yoga@5.21.2
- @graphql-yoga/plugin-apollo-inline-trace@3.21.2
0.16.1
Patch Changes
- Updated dependencies
[
4b43efd]:- graphql-yoga@5.21.1
- @graphql-yoga/plugin-apollo-inline-trace@3.21.1
0.16.0
Patch Changes
- Updated dependencies
[
e263f7e]:- graphql-yoga@5.21.0
- @graphql-yoga/plugin-apollo-inline-trace@3.21.0
0.15.0
Patch Changes
- Updated dependencies
[
93f1dc0]:- graphql-yoga@5.20.0
- @graphql-yoga/plugin-apollo-inline-trace@3.20.0
0.14.0
Patch Changes
- Updated dependencies
[
7e0aaf6]:- graphql-yoga@5.19.0
- @graphql-yoga/plugin-apollo-inline-trace@3.19.0
0.13.1
Patch Changes
- Updated dependencies
[
f98149a,9a221c3,f98149a]:- @graphql-yoga/plugin-apollo-inline-trace@3.18.1
- graphql-yoga@5.18.1
0.13.0
Patch Changes
- Updated dependencies
[
3eabd17]:- graphql-yoga@5.18.0
- @graphql-yoga/plugin-apollo-inline-trace@3.18.0
0.12.1
Patch Changes
-
#4302
c27f550Thanks @beaumontjonathan! - Bump @whatwg-node/promise-helpers to fix missing export unfakePromise -
Updated dependencies [
c27f550]:- graphql-yoga@5.17.1
- @graphql-yoga/plugin-apollo-inline-trace@3.17.1
0.12.0
Patch Changes
- #4288
66c370cThanks @EmrysMyrddin! - dependencies updates:- Updated dependency
@graphql-tools/utils@^10.11.0↗︎ (from^10.9.1, independencies)
- Updated dependency
- Updated dependencies
[
66c370c,66c370c]:- graphql-yoga@5.17.0
- @graphql-yoga/plugin-apollo-inline-trace@3.17.0
0.11.2
Patch Changes
- Updated dependencies
[
b8d2f70,ba38629]:- @graphql-yoga/plugin-apollo-inline-trace@3.16.2
- graphql-yoga@5.16.2
0.11.1
Patch Changes
- Updated dependencies
[
6f83cea,e1f52b6,6f83cea]:- graphql-yoga@5.16.1
- @graphql-yoga/plugin-apollo-inline-trace@3.16.1
0.11.0
Patch Changes
- Updated dependencies
[
a4e1c5f,0a7a635]:- graphql-yoga@5.16.0
- @graphql-yoga/plugin-apollo-inline-trace@3.16.0
0.10.2
Patch Changes
-
#4113
9236d45Thanks @renovate! - dependencies updates:- Updated dependency
@graphql-tools/utils@^10.9.1↗︎ (from10.8.6, independencies)
- Updated dependency
-
#4123
2b09faaThanks @renovate! - dependencies updates:- Updated dependency
@apollo/server-gateway-interface@^2.0.0↗︎ (from^1.1.1, independencies)
- Updated dependency
-
Updated dependencies [
e7b8906]:- graphql-yoga@5.15.2
- @graphql-yoga/plugin-apollo-inline-trace@3.15.2
0.10.1
Patch Changes
- Updated dependencies
[
ecd605b]:- graphql-yoga@5.15.1
- @graphql-yoga/plugin-apollo-inline-trace@3.15.1
0.10.0
Patch Changes
- Updated dependencies
[
ccb5c53,ccb5c53]:- graphql-yoga@5.15.0
- @graphql-yoga/plugin-apollo-inline-trace@3.15.0
0.9.0
Minor Changes
- #4020
dcfd110Thanks @EmrysMyrddin! - Various improvements of Apollo Usage Report plugin. It is now production ready !- Report referenced field by types
- Batched traces
- Report gzip compression
- Nonexecutable operations handling to match Apollo’s behavior
- Fix schema ID generation to match Apollo’s algorithm
Patch Changes
-
#4020
dcfd110Thanks @EmrysMyrddin! - dependencies updates:- Added dependency
@apollo/server-gateway-interface@^1.1.1↗︎ (todependencies) - Added dependency
@apollo/utils.usagereporting@^2.1.0↗︎ (todependencies) - Added dependency
@graphql-tools/utils@10.9.0-alpha-20250601230319-2f5f24f393b56915c1c913d3f057531f79991587↗︎ (todependencies)
- Added dependency
-
#4078
eec82d9Thanks @renovate! - dependencies updates:- Updated dependency
@graphql-tools/utils@10.9.0-alpha-20250602135508-a77e43b8ef641aa0bd366dfbddc68b4c774f2882↗︎ (from10.9.0-alpha-20250601230319-2f5f24f393b56915c1c913d3f057531f79991587, independencies)
- Updated dependency
-
#4088
98c82a5Thanks @EmrysMyrddin! - dependencies updates:- Updated dependency
@graphql-tools/utils@10.8.6↗︎ (from10.9.0-alpha-20250602135508-a77e43b8ef641aa0bd366dfbddc68b4c774f2882, independencies)
- Updated dependency
-
Updated dependencies [
6e04a7f,5f75a42,98c82a5,98c82a5]:- @graphql-yoga/plugin-apollo-inline-trace@3.14.0
- graphql-yoga@5.14.0
0.8.6
Patch Changes
- Updated dependencies
[
8b41a52]:- graphql-yoga@5.13.5
- @graphql-yoga/plugin-apollo-inline-trace@3.13.5
0.8.5
Patch Changes
-
#3995
000c33dThanks @enisdenjo! - Update whatwg-node packagesIn light of https://github.com/ardatan/whatwg-node/pull/2305. Please upgrade as soon as possible!
-
Updated dependencies [
000c33d]:- @graphql-yoga/plugin-apollo-inline-trace@3.13.4
- graphql-yoga@5.13.4
0.8.4
Patch Changes
- Updated dependencies
[
1773c8c,3a7ef74]:- graphql-yoga@5.13.3
- @graphql-yoga/plugin-apollo-inline-trace@3.13.3
0.8.3
Patch Changes
- Updated dependencies
[
abe91bd,9311842]:- graphql-yoga@5.13.2
- @graphql-yoga/plugin-apollo-inline-trace@3.13.2
0.8.2
Patch Changes
- Updated dependencies
[
dee7995,dee7995]:- @graphql-yoga/plugin-apollo-inline-trace@3.13.1
- graphql-yoga@5.13.1
0.8.1
Patch Changes
- #3860
9599d45Thanks @renovate! - dependencies updates:- Added dependency
@whatwg-node/promise-helpers@^1.2.4↗︎ (todependencies)
- Added dependency
0.8.0
Patch Changes
- Updated dependencies
[
63b78d5,63b78d5,63b78d5,6ed67e8]:- @graphql-yoga/plugin-apollo-inline-trace@3.13.0
- graphql-yoga@5.13.0
0.7.3
Patch Changes
- Updated dependencies
[
a6b3de9]:- graphql-yoga@5.12.2
- @graphql-yoga/plugin-apollo-inline-trace@3.12.3
0.7.2
Patch Changes
- Updated dependencies
[
fbf328c]:- graphql-yoga@5.12.1
- @graphql-yoga/plugin-apollo-inline-trace@3.12.2
0.7.1
Patch Changes
- Updated dependencies
[
1d438ce]:- @graphql-yoga/plugin-apollo-inline-trace@3.12.1
0.7.0
Patch Changes
- Updated dependencies
[
ea63828,96498ee,5150146,5150146]:- @graphql-yoga/plugin-apollo-inline-trace@3.12.0
- graphql-yoga@5.12.0
0.6.0
Patch Changes
- Updated dependencies
[
5fd15b8,d13b8a4]:- graphql-yoga@5.11.0
- @graphql-yoga/plugin-apollo-inline-trace@3.11.0
0.5.9
Patch Changes
-
#3647
31b7754Thanks @ardatan! - Wait for setting schemaId to prevent race condition -
Updated dependencies [
31b7754]:- @graphql-yoga/plugin-apollo-inline-trace@3.10.12
0.5.8
Patch Changes
- Updated dependencies
[
1c055f5]:- graphql-yoga@5.10.11
- @graphql-yoga/plugin-apollo-inline-trace@3.10.11
0.5.7
Patch Changes
- #3660
d4cbae1Thanks @renovate! - dependencies updates:- Updated dependency
tslib@^2.8.1↗︎ (from^2.5.2, independencies)
- Updated dependency
- Updated dependencies
[
d4cbae1]:- @graphql-yoga/plugin-apollo-inline-trace@3.10.10
- graphql-yoga@5.10.10
0.5.6
Patch Changes
- Updated dependencies
[
d24c5d5,d24c5d5]:- graphql-yoga@5.10.9
- @graphql-yoga/plugin-apollo-inline-trace@3.10.9
0.5.5
Patch Changes
- Updated dependencies
[
ed344ea]:- graphql-yoga@5.10.8
- @graphql-yoga/plugin-apollo-inline-trace@3.10.8
0.5.4
Patch Changes
- #3547
8fee214Thanks @Urigo! - dependencies updates:- Removed dependency
@graphql-tools/utils@^10.6.1↗︎ (frompeerDependencies) - Removed dependency
@whatwg-node/fetch@^0.10.1↗︎ (frompeerDependencies)
- Removed dependency
- Updated dependencies
[
8fee214,1df4912]:- graphql-yoga@5.10.7
- @graphql-yoga/plugin-apollo-inline-trace@3.10.7
0.5.3
Patch Changes
- Updated dependencies
[
121ccba]:- graphql-yoga@5.10.6
- @graphql-yoga/plugin-apollo-inline-trace@3.10.6
0.5.2
Patch Changes
- #3549
05fe345Thanks @ardatan! - dependencies updates:- Removed dependency
@graphql-tools/utils@^10.6.1↗︎ (frompeerDependencies) - Removed dependency
@whatwg-node/fetch@^0.10.1↗︎ (frompeerDependencies)
- Removed dependency
- Updated dependencies
[
eca7cd1,05fe345]:- graphql-yoga@5.10.5
- @graphql-yoga/plugin-apollo-inline-trace@3.10.5
0.5.1
Patch Changes
- #3520
944ecd5Thanks @ardatan! - dependencies updates:- Updated dependency
@graphql-tools/utils@^10.6.1↗︎ (from^10.0.0, inpeerDependencies)
- Updated dependency
- Updated dependencies
[
944ecd5,944ecd5]:- @graphql-yoga/plugin-apollo-inline-trace@3.10.4
- graphql-yoga@5.10.4
0.5.0
Minor Changes
- #3458
cb29c6cThanks @kroupacz! - ### Removed- Breaking change remove option to set
clientNameandclientVersionas a staticstringinApolloUsageReportOptions
- Breaking change remove option to set
Patch Changes
- #3488
a4bc07fThanks @kroupacz! - fixed: move logic fromonEnvelopedhook toonParsehook (onParseEnd) which prevents theoperationNamecould be missing.
0.4.3
Patch Changes
- Updated dependencies
[
c93366d,c93366d]:- graphql-yoga@5.10.3
- @graphql-yoga/plugin-apollo-inline-trace@3.10.3
0.4.2
Patch Changes
- Updated dependencies
[
7a413bc,7a413bc]:- graphql-yoga@5.10.2
- @graphql-yoga/plugin-apollo-inline-trace@3.10.2
0.4.1
Patch Changes
- #3479
20cd9b6Thanks @ardatan! - dependencies updates:- Updated dependency
@whatwg-node/fetch@^0.10.1↗︎ (from^0.9.22, inpeerDependencies)
- Updated dependency
- Updated dependencies
[
20cd9b6,20cd9b6]:- @graphql-yoga/plugin-apollo-inline-trace@3.10.1
- graphql-yoga@5.10.1
0.4.0
Patch Changes
-
#3455
6e2ab86Thanks @kroupacz! - - fixed: get specific or the nearest possible trace node if something fails atnon-nullableGraphQL query field -
Updated dependencies [
6e2ab86,f81501c]:- @graphql-yoga/plugin-apollo-inline-trace@3.10.0
- graphql-yoga@5.10.0
0.3.0
Patch Changes
- #3457
2523d9fThanks @kroupacz! - ### Fixed- do not set default values for
clientNameandclientVersion
- do not set default values for
- Updated dependencies
[
2523d9f,87ee333]:- graphql-yoga@5.9.0
- @graphql-yoga/plugin-apollo-inline-trace@3.9.0
0.2.0
Patch Changes
-
#3445
6bb19edThanks @ardatan! - dependencies updates:- Updated dependency
@whatwg-node/fetch@^0.9.22↗︎ (from^0.9.17, inpeerDependencies)
- Updated dependency
-
18fe916Thanks @kroupacz! - - Send ApolloclientName,clientVersionandagentVersion(agent name) with trace. -
Updated dependencies [
6bb19ed,18fe916,6bb19ed]:- @graphql-yoga/plugin-apollo-inline-trace@3.8.0
- graphql-yoga@5.8.0