graphql icon indicating copy to clipboard operation
graphql copied to clipboard

chore(deps): update apollo graphql packages to v2 (major)

Open renovate[bot] opened this issue 2 years ago β€’ 1 comments

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
@apollo/gateway 0.52.1 -> 2.1.2 age adoption passing confidence
@apollo/subgraph 0.5.1 -> 2.1.2 age adoption passing confidence

Release Notes

apollographql/federation (@​apollo/gateway)

v2.1.2

Compare Source

  • Allow fields with arguments in @requires PR #​2120.
  • Fix potential inefficient planning due to __typename PR #​2137.
  • Fix potential assertion during query planning PR #​2133.
  • Fix some defer query plans having invalid result sets (with empty branches) PR #​2125.
  • Fix defer information lost when cloning fetch group (resulting in non-deferred parts) PR #​2129.
  • Fix directives on fragment spread being lost PR #​2126.

v2.1.1

Compare Source

v2.1.0

Compare Source

  • Fix issue where fragment expansion can erase applied directives (most notably @defer) PR #​2093.
  • Fix abnormally high memory usage when extracting subgraphs for some fed1 supergraphs (and small other memory footprint improvements) PR #​2089.
  • Fix issue with fragment reusing code something mistakenly re-expanding fragments PR #​2098.
  • Fix issue when type is only reachable through a @​provides PR #​2083.
  • Fix case where some key field necessary to a @require fetch were not previously fetched PR #​2075.
  • Add type definitions to schema extensions PR #​2081
  • Update peer dependency graphql to ^16.5.0 to use GraphQLErrorOptions PR #​2060
  • Upgrade underlying @apollo/utils.fetcher to support aborting a request. This is a type-only change, and will not impact the underlying runtime. PR #​2017.
  • Some TypeScript types, such as the arguments and return value of GraphQLDataSource.process, are defined using types from the @apollo/server-gateway-interface package instead of from apollo-server-types and apollo-server-core. This is intended to be fully backwards-compatible; please file an issue if this leads to TypeScript compilation issues. PR #​2044
  • Don't require @link when using @composeDirective PR #​2046
  • Don't do debug logging by default PR #​2048
  • Add @composeDirective directive to specify directives that should be merged to the supergraph during composition PR #​1996.
  • Fix fragment reuse in subgraph fetches PR #​1911.
  • Allow passing a custom fetcher PR #​1997.
    • UNBREAKING: Previous 2.1.0 alphas removed the custom fetcher for Apollo Uplink. This re-adds that parameter, and requires the fetcher to have the AbortSignal interface https://fetch.spec.whatwg.org/#requestinit.
  • The method RemoteGraphQLDataSource.errorFromResponse now returns a GraphQLError (as defined by graphql) rather than an ApolloError (as defined by apollo-server-errors). PR #​2028
    • BREAKING: If you call RemoteGraphQLDataSource.errorFromResponse manually and expect its return value to be a particular subclass of GraphQLError, or if you expect the error received by didEncounterError to be a particular subclass of GraphQLError, then this change may affect you. We recommend checking error.extensions.code instead.
  • The LocalGraphQLDataSource class no longer supports the undocumented __resolveObject Apollo Server feature. PR #​2007
    • BREAKING: If you relied on the undocumented __resolveObject feature with LocalGraphQLDataSource, it will no longer work. If this affects you, file an issue and we can help you find a workaround.
  • Expose document representation of sub-query request within GraphQLDataSourceProcessOptions so that it is available to RemoteGraphQLDataSource.process and RemoteGraphQLDataSource.willSendRequest PR#​1878
  • Fix issue when using a type condition on an inaccessible type in @require #​1873.
    • BREAKING: this fix required passing a new argument to the executeQueryPlan method, which is technically exported by the gateway. Most users of the gateway should not call this method directly (which is exported mainly for testing purposes in the first place) and will thus be unaffected, but if you do call this method directly, you will have to pass the new argument when upgrading. See the method documentation for details.
  • Cleanup error related code, adding missing error code to a few errors PR #​1914.
  • Fix issue generating plan for a "diamond-shaped" dependency PR #​1900.
  • Fix issue computing query plan costs that can lead to extra unnecessary fetches PR #​1937.
  • Reject directive applications within fields of @key, @provides and @requiresPR #​1975.
    • BREAKING: previously, directive applications within a @key, @provides or @requires were parsed but not honored in any way. As this change reject such applications (at composition time), it could theoretically require to remove some existing (ignored) directive applications within a @key, @provides or @requires.
  • Move DEFAULT_UPLINK_ENDPOINTS to static member of UplinkSupergraphManager PR #​1977.
  • Add node-fetch as a runtime dependency PR #​1970.
  • Add timeouts when making requests to Apollo Uplink PR #​1950.
    • BREAKING: In 2.1.0-alpha.0, UplinkSupergraphManager was introduced and allowed passing a fetcher argument to the constructor. That parameter has been removed, at least until we figure out how to support the signal param more generically in apollo-utils types.
  • Avoid type-explosion with fed1 supergraphs using a fed2 query planner PR #​1994.
  • Add callback when fetching a supergraph from Apollo Uplink fails PR #​1812. -BREAKING: Previously, if a custom fetcher was passed to the gateway instance, that would be passed to the UplinkSupergraphManager. That meant that fetcher customizations intended for RemoteGraphQLDataSource were also added to UplinkFetcher/UplinkSupergraphManager. Now, the fetcher passed to the gateway instance will not be passed to UplinkSupergraphManager. If your team relies on fetcher customizations being used for polling Apollo Uplink, please file an issue.
  • Expand support for Node.js v18 PR #​1884

v2.0.5

Compare Source

  • Fix bug with unsatisfiable query branch when handling federation 1 supergraph PR #​1908.

v2.0.4

Compare Source

  • Fix issue when all root operations were defined in an extend schema PR #​1875.

v2.0.3

Compare Source

  • Fix bug with type extension of empty type definition PR #​1821
  • Fix output of printSubgraphSchema method, ensuring it can be read back by composition and buildSubgraphSchema PR #​1831.
  • Fix issue with @requires and conditional queries (@include/@skip) 1835.
  • Fix bug with field covariance when the underlying plan use type-explosion 1859.

v2.0.2

Compare Source

  • The fetch implementation used by default by UplinkFetcher and RemoteGraphQLDataSource is now imported from make-fetch-happen v10 instead of v8. The fetcher used by RemoteGraphQLDataSource no longer limits the number of simultaneous requests per subgraph (or specifically, per host/port pair) to 15 by default; instead, there is no limit. (If you want to restore the previous behavior, install make-fetch-happen, import fetcher from it, and pass new RemoteGraphQLDataSource({ fetcher: fetcher.defaults(maxSockets: 15)})) in your buildService option.) Note that if you invoke the fetcher yourself in a RemoteGraphQLDataSource subclass, you should ensure that you pass "plain" objects rather than Headers or Request objects, as the newer version has slightly different logic about how to recognize Headers and Request objects. We have adjusted the TypeScript types for fetcher so that only these "plain" objects (which result in consistent behavior across all fetcher implementations) are permitted. PR #​1805
  • BREAKING: We no longer export a getDefaultFetcher function. This function returned the default fetch implementation used to talk to Uplink (which is distinct from the default fetch implementation used by RemoteGraphQLDataSource to talk to subgraphs). It was the fetcher from make-fetch-happen v8 with some preset configuration relating to caching and request headers. However, the caching configuration was not actually being used when talking to Uplink (as we talk to Uplink over POST requests, and the Uplink protocol has an application-level mechanism for avoiding unnecessary large responses), and the request headers were already being provided explicitly by the Uplink client code. Since this release is also upgrading make-fetch-happen, it is impossible to promise that there would be no behavior change at all to the fetcher returned from make-fetch-happen, and as none of the preset configuration is actually relevant to the internal use of getDefaultFetcher (which now just uses make-fetch-happens without extra configuration), we have removed the function. If you were using this function, you can replace const fetcher = getDefaultFetcher() with import fetcher from 'make-fetch-happen'. PR #​1805
  • Fix Schema.clone when directive application happens before definition PR #​1785
  • More helpful error message for errors encountered while reading supergraphs generated pre-federation 2 PR #​1796
  • Fix handling of @​require "chains" (a @​require whose fields have @​require themselves) PR #​1790
  • Fix bug applying an imported federation directive on another directive definition PR #​1797.
  • Fix bug where planning a query with @require impacts the plans of followup queries PR #​1783.
  • Improve fed1 schema support during composition PR #​1735
  • Add missing @​apollo/federation-internals dependency to gateway PR #​1721
  • Improve merging of groups during @require handling in query planning PR #​1732
  • Move __resolveReference resolvers on to extensions PR #​1746
  • Add gateway version to schema extensions PR #​1751
  • Honor directive imports when directive name is spec name PR #​1720
  • Migrate to @apollo/utils packages for createSHA and isNodeLike PR #​1765

v2.0.1

Compare Source

  • Use for: SECURITY in the core/link directive application in the supergraph for @inaccessible PR #​1715

v2.0.0

Compare Source

  • Previous preview release promoted to general availability! Please see previous changelog entries for full info.
apollographql/federation (@​apollo/subgraph)

v2.1.2

Compare Source

v2.1.1

Compare Source

v2.1.0

Compare Source

v2.0.5

Compare Source

v2.0.4

Compare Source

v2.0.3

Compare Source

  • Fix output of printSubgraphSchema method, ensuring it can be read back by composition and buildSubgraphSchema PR #​1831.
  • Fix definition of @key to be repeatable PR #​1826.

v2.0.2

Compare Source

v2.0.1

Compare Source

  • Released in sync with other federation packages but no changes to this package.

v2.0.0

Compare Source

  • Previous preview release promoted to general availability! Please see previous changelog entries for full info.

Configuration

πŸ“… Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

β™» Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

πŸ”• Ignore: Close this PR and you won't be reminded about these updates again.


  • [ ] If you want to rebase/retry this PR, click this checkbox.

This PR has been generated by Mend Renovate. View repository job log here.

renovate[bot] avatar Apr 11 '22 23:04 renovate[bot]

Note to self: needs GQL v16 installed as dev dependency

kamilmysliwiec avatar Apr 15 '22 09:04 kamilmysliwiec

Let's track this here https://github.com/nestjs/graphql/pull/2636/

kamilmysliwiec avatar Feb 07 '23 10:02 kamilmysliwiec