Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.1 - autoclosed #420

Closed
wants to merge 1 commit into from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Oct 24, 2024

This PR contains the following updates:

Package Update Change
ghcr.io/apollographql/router minor v1.56.0 -> v1.58.1

Release Notes

apollographql/router (ghcr.io/apollographql/router)

v1.58.1

Compare Source

[!IMPORTANT]
If you have enabled Distributed query plan caching, this release contains changes which necessarily alter the hashing algorithm used for the cache keys. On account of this, you should anticipate additional cache regeneration cost when updating between these versions while the new hashing algorithm comes into service.

🐛 Fixes
Particular supergraph telemetry customizations using the query selector do not error (PR #​6324)

Telemetry customizations like those featured in the request limits telemetry documentation now work as intended when using the query selector on the supergraph layer. Prior to this fix, this was sometimes causing a this is a bug and should not happen error, but is now resolved.

By @​bnjjj in https://github.com/apollographql/router/pull/6324

Native query planner now receives both "plan" and "path" limits configuration (PR #​6316)

The native query planner now correctly sets two experimental configuration options for limiting query planning complexity. These were previously available in the configuration and observed by the legacy planner, but were not being passed to the new native planner until now:

  • supergraph.query_planning.experimental_plans_limit
  • supergraph.query_planning.experimental_paths_limit

By @​goto-bus-stop in https://github.com/apollographql/router/pull/6316

v1.58.0

Compare Source

[!IMPORTANT]
If you have enabled Distributed query plan caching, this release contains changes which necessarily alter the hashing algorithm used for the cache keys. On account of this, you should anticipate additional cache regeneration cost when updating between these versions while the new hashing algorithm comes into service.

🚀 Features

Support DNS resolution strategy configuration (PR #​6109)

The router now supports a configurable DNS resolution strategy for the URLs of coprocessors and subgraphs.
The new option is called dns_resolution_strategy and supports the following values:

  • ipv4_only - Only query for A (IPv4) records.
  • ipv6_only - Only query for AAAA (IPv6) records.
  • ipv4_and_ipv6 - Query for both A (IPv4) and AAAA (IPv6) records in parallel.
  • ipv6_then_ipv4 - Query for AAAA (IPv6) records first; if that fails, query for A (IPv4) records.
  • ipv4_then_ipv6(default) - Query for A (IPv4) records first; if that fails, query for AAAA (IPv6) records.

You can change the DNS resolution strategy applied to a subgraph's URL:

traffic_shaping:
  all:
    dns_resolution_strategy: ipv4_then_ipv6

You can also change the DNS resolution strategy applied to a coprocessor's URL:

coprocessor:
  url: http://coprocessor.example.com:8081
  client:
    dns_resolution_strategy: ipv4_then_ipv6

By @​IvanGoncharov in https://github.com/apollographql/router/pull/6109

Configuration options for HTTP/1 max headers and buffer limits (PR #​6194)

This update introduces configuration options that allow you to adjust the maximum number of HTTP/1 request headers and the maximum buffer size allocated for headers.

By default, the router accepts HTTP/1 requests with up to 100 headers and allocates ~400 KiB of buffer space to store them. If you need to handle requests with more headers or require a different buffer size, you can now configure these limits in the router's configuration file:

limits:
  http1_request_max_headers: 200
  http1_request_max_buf_size: 200kib

If you are using the router as a Rust crate, the http1_request_max_buf_size option requires the hyper_header_limits feature and also necessitates using Apollo's fork of the Hyper crate until the changes are merged upstream.
You can include this fork by adding the following patch to your Cargo.toml file:

[patch.crates-io]
"hyper" = { git = "https://github.com/apollographql/hyper.git", tag = "header-customizations-20241108" }

By @​IvanGoncharov in https://github.com/apollographql/router/pull/6194

Compress subgraph operations by generating fragments (PR #​6013)

The router now compresses operations sent to subgraphs by default by generating fragment
definitions and using them in the operation.

This change enables generate_query_fragments by default while disabling experimental_reuse_query_fragments. When enabled, experimental_reuse_query_fragments attempts to intelligently reuse the fragment definitions
from the original operation. However, fragment generation with generate_query_fragments is much faster and produces better outputs in most cases.

If you are relying on the shape of fragments in your subgraph operations or tests, you can opt out of the new algorithm with the configuration below.

Note: The subgraph operations generated by the query planner are not guaranteed consistent release over release. We strongly recommend against relying on the shape of planned subgraph operations, as new router features and optimizations will continuously affect it. We plan to remove experimental_reuse_query_fragments in a future release.

supergraph:
  generate_query_fragments: false
  experimental_reuse_query_fragments: true

By @​lrlna in https://github.com/apollographql/router/pull/6013

Add subgraph request id (PR #​5858)

The router now supports a subgraph request ID that is a unique string identifying a subgraph request and response. It allows plugins and coprocessors to keep some state per subgraph request by matching on this ID. It's available in coprocessors as subgraphRequestId and Rhai scripts as request.subgraph.id and response.subgraph.id.

By @​Geal in https://github.com/apollographql/router/pull/5858

Add extensions.service for all subgraph errors (PR #​6191)

For improved debuggability, the router now supports adding a subgraph's name as an extension to all errors originating from the subgraph.

If include_subgraph_errors is true for a particular subgraph, all errors originating in this subgraph will have the subgraph's name exposed as a service extension.

You can enable subgraph errors with the following configuration:

include_subgraph_errors:
  all: true # Propagate errors from all subgraphs

Note: This option is enabled by default by the router's dev mode.

Consequently, when a subgraph returns an error, it will have a service extension with the subgraph name as its value. The following example shows the extension for a products subgraph:

{
  "data": null,
  "errors": [
    {
      "message": "Invalid product ID",
      "path": [],
      "extensions": {
        "service": "products"
      }
    }
  ]
}

By @​IvanGoncharov in https://github.com/apollographql/router/pull/6191

Add @context support in the native query planner (PR #​6310)

The @context feature is now available in the native query planner.
This brings the native query planner to feature parity with the legacy query planner for all Federation v2 graphs. The native query planner can be enabled with the following configuration:

experimental_query_planner_mode: new

By @​clenfest, @​TylerBloom in https://github.com/apollographql/router/pull/6310

🐛 Fixes

Remove noisy demand control logs (PR #​6192)

Demand control no longer logs warnings when a subgraph response is missing a requested field.

By @​tninesling in https://github.com/apollographql/router/pull/6192

Renamed headers' original values can again be propagated (PR #​6281)

PR #​4535 introduced a regression where the following header propagation config would not work:

headers:
- propagate:
    named: a
    rename: b
- propagate:
    named: a
    rename: c

The goal of the original PR was to prevent multiple headers from being mapped to a single target header. However, it did not consider renames and instead prevented multiple mappings from the same source header.
The router now propagates headers properly and ensures that a target header is only propagated to once.

By @​BrynCooke in https://github.com/apollographql/router/pull/6281

Introspection response deduplication should always produce results (Issue #​6249)

To reduce CPU usage, query planning and introspection queries are deduplicated. In some cases, deduplicated introspection queries were not receiving their result. This issue has been fixed, and the router now sends results in all cases.

By @​Geal in https://github.com/apollographql/router/pull/6257

Don't log response data upon notification failure for subgraph batching (PR #​6150)

For a subgraph batching operation, the router now doesn't log the entire subgraph response when failing to notify a waiting batch participant. This saves the router from logging the large amount of data (PII and/or non-PII data) that a subgraph response may contain.

By @​garypen in https://github.com/apollographql/router/pull/6150

Move heavy computation to a thread pool with a priority queue (PR #​6247)

The router now avoids blocking threads when executing asynchronous code by using a thread pool with a priority queue.

This improves the performance of the following components that can take non-trivial amounts of CPU time:

  • GraphQL parsing
  • GraphQL validation
  • Query planning
  • Schema introspection

The size of the thread pool is based on the number of available CPU cores.

The thread pool replaces the router's prior implementation that used Tokio’s spawn_blocking.

apollo.router.compute_jobs.queued is a new gauge metric for the number of items in the thread pool's priority queue.

Note: when the native query planner is enabled, the dedicated queue of the legacy query planner is no longer used, so the apollo.router.query_planning.queued metric is no longer emitted.

By @​SimonSapin in https://github.com/apollographql/router/pull/6247

Limit the amount of GraphQL validation errors returned per response (PR #​6187)

When an invalid query is submitted, the router now returns at most one hundred GraphQL parsing and validation errors in a response. This prevents generating too large of a response for a nonsensical document.

By @​goto-bus-stop in https://github.com/apollographql/router/pull/6187

Remove placeholders from file upload query variables (PR #​6293)

Previously, file upload query variables in subgraph requests incorrectly contained internal placeholders.
According to the GraphQL Multipart Request Spec, these variables should be set to null.
This issue has been fixed by ensuring that the router complies with the specification and improving compatibility with subgraphs handling file uploads.

By @​IvanGoncharov in https://github.com/apollographql/router/pull/6293

Overhead processing metrics should exclude subgraph response time when deduplication is enabled (PR #​6207)

The router's calculated overhead processing time has been fixed, where the time spent waiting for the subgraph response of a deduplicated request had been incorrectly included.

By @​Geal in https://github.com/apollographql/router/pull/6207

Fix demand control panic for custom scalars that represent non-GraphQL-compliant JSON (PR #​6288)

Previously, a panic could be triggered in the router's demand control plugin with the following schema:

scalar ArbitraryJson

type MyInput {
    json: ArbitraryJson
}

type Query {
    fetch(args: MyInput): Int
}

Then, submitting the query

query FetchData(: ArbitraryJson) {
    fetch(args: {
        json: 
    })
}

and variables

{
    "myJsonValue": {
        "field.with.dots": 1
    }
}

During scoring, the demand control plugin would attempt to convert the variable structure into a GraphQL-compliant structure requiring valid GraphQL names as keys. The dot characters in the keys however would cause a panic.

With this fix, only the GraphQL compliant part of the input object is scored, and the arbitrary JSON marked by the custom scalar is scored as an opaque scalar (similar to how built-ins like Int or String are processed).

By @​tninesling in https://github.com/apollographql/router/pull/6288

Fix incorrect overriding of concrete type names with interface names when merging responses (PR #​6250)

When using @interfaceObject, differing pieces of data can come back with either concrete types or interface types depending on the source. Previously, receiving the data in a particular order could incorrectly result in the interface name of a type overwriting its concrete name.

To make the response merging order-agnostic, the router now checks the schema to ensure concrete types are not overwritten with interfaces or less specific types.

By @​tninesling in https://github.com/apollographql/router/pull/6250

🛠 Maintenance

Query planner cache key improvements (Issue #​5160)

Several performance improvements have been implemented for query plan cache key generation. In particular, the distributed cache's key format has changed, which adds prefixes to the different key segments to help in debugging.

By @​Geal in https://github.com/apollographql/router/pull/6206

Add entity caching invalidation configuration metrics (PR #​6286)

We've added metrics for our analytics to know if entity caching invalidation is enabled.

By @​bnjjj in https://github.com/apollographql/router/pull/6286

Avoid creating stub span for supergraph events if current span exists (PR #​6096)

The router optimized its telemetry implementation by not creating a redundant span when it already has a span available to use the span's extensions for supergraph events.

By @​bnjjj in https://github.com/apollographql/router/pull/6096

📚 Documentation

Clarify docs for authorization directive composition (PR #​6216)

The docs for authorization directive composition have been clarified, including corrected code examples.

By @​Meschreiber in https://github.com/apollographql/router/pull/6216

v1.57.1

Compare Source

🐛 Fixes
Progressive override: fix query planner cache warmup (PR #​6108)

This fixes an issue in progressive override where the override labels were not transmitted to the query planner during cache warmup. Queries were correctly using the overridden fields at first, but after an update, reverted to non overridden fields, and could not recover.

By @​Geal in https://github.com/apollographql/router/pull/6108

v1.57.0

Compare Source

[!IMPORTANT]
If you have enabled Distributed query plan caching, updates to the query planner in this release will result in query plan caches being re-generated rather than re-used. On account of this, you should anticipate additional cache regeneration cost when updating between these versions while the new query plans come into service.

🚀 Features
Remove legacy schema introspection (PR #​6139)

Schema introspection in the router now runs natively without JavaScript. We have high confidence that the new native implementation returns responses that match the previous Javascript implementation, based on differential testing: fuzzing arbitrary queries against a large schema, and testing a corpus of customer schemas against a comprehensive query.

Changes to the router's YAML configuration:

  • The experimental_introspection_mode key has been removed, with the new mode as the only behavior in this release.
  • The supergraph.query_planning.legacy_introspection_caching key is removed, with the behavior in this release now similar to what was false: introspection responses are not part of the query plan cache but instead in a separate, small in-memory—only cache.

When using the above deprecated configuration options, the router's automatic configuration migration will ensure that existing configuration continue to work until the next major version of the router. To simplify major upgrades, we recommend reviewing incremental updates to your YAML configuration by comparing the output of ./router config upgrade --config path/to/config.yaml with your existing configuration.

By @​SimonSapin in https://github.com/apollographql/router/pull/6139

Support new request_context selector for telemetry (PR #​6160)

The router supports a new request_context selector for telemetry that enables access to the supergraph schema ID.

You can configure the context to access the supergraph schema ID at the router service level:

telemetry:
  instrumentation:
    events:
      router:
        my.request_event:
          message: "my request event message"
          level: info
          on: request
          attributes:
            schema.id:
              request_context: "apollo::supergraph_schema_id" # The key containing the supergraph schema id

You can use the selector in any service at any stage. While this example applies to events attributes, the selector can also be used on spans and instruments.

By @​bnjjj in https://github.com/apollographql/router/pull/6160

Support reading and setting port on request URIs using Rhai (Issue #​5437)

Custom Rhai scripts in the router now support the request.uri.port and request.subgraph.uri.port functions for reading and setting URI ports. These functions enable you to update the full URI for subgraph fetches. For example:

fn subgraph_service(service, subgraph){
    service.map_request(|request|{
        log_info(``);
        if request.subgraph.uri.port == {} {
            log_info("Port is not explicitly set");
        }
        request.subgraph.uri.host = "api.apollographql.com";
        request.subgraph.uri.path = "/api/graphql";
        request.subgraph.uri.port = 1234;
        log_info(``);
    });
}

By @​lleadbet in https://github.com/apollographql/router/pull/5439

🐛 Fixes
Fix various edge cases for __typename field (PR #​6009)

The router now correctly handles the __typename field used on operation root types, even when the subgraph's root type has a name that differs from the supergraph's root type.

For example, given a query like this:

{
  ...RootFragment
}

fragment RootFragment on Query {
  __typename
  me {
    name
  }
}

Even if the subgraph's root type returns a __typename that differs from Query, the router will still use Query as the value of the __typename field.

This change also includes fixes for other edge cases related to the handling of __typename fields. For a detailed technical description of the edge cases that were fixed, please see this description.

By @​IvanGoncharov in https://github.com/apollographql/router/pull/6009

Support uri and method properties on router "request" objects in Rhai (PR #​6147)

The router now supports accessing request.uri and request.method properties from custom Rhai scripts. Previously, when trying to access request.uri and request.method on a router request in Rhai, the router would return error messages stating the properties were undefined.

An example Rhai script using these properties:

fn router_service(service) {
  let router_request_callback = Fn("router_request_callback");
  service.map_request(router_request_callback);
}

fn router_request_callback (request) {
  log_info(`Router Request... Host: , Path: `);
}

By @​andrewmcgivery in https://github.com/apollographql/router/pull/6114

Cost calculation for subgraph requests with named fragments (PR #​6162)

In some cases where subgraph GraphQL operations contain named fragments and abstract types, demand control used the wrong type for cost calculation, and could reject valid operations. Now, the correct type is used.

This fixes errors of the form:

Attempted to look up a field on type MyInterface, but the field does not exist

By @​goto-bus-stop in https://github.com/apollographql/router/pull/6162

Federation v2.9.3 (PR #​6161)

This release updates to Federation v2.9.3, with query planner fixes:

  • Fixes a query planning bug where operation variables for a subgraph query wouldn't match what's used in that query.
  • Fixes a query planning bug where directives applied to __typename may be omitted in the subgraph query.
  • Fixes a query planning inefficiency where some redundant subgraph queries were not removed.
  • Fixes a query planning inefficiency where some redundant inline fragments in @key/@requires selection sets were not optimized away.
  • Fixes a query planning inefficiency where unnecessary subgraph jumps were being added when using @context/@fromContext.

By @​sachindshinde in https://github.com/apollographql/router/pull/6161


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot requested a review from alessbell as a code owner October 24, 2024 08:13
@renovate renovate bot enabled auto-merge October 24, 2024 08:13
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from 7845efb to 3523220 Compare October 27, 2024 10:30
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 - autoclosed Oct 27, 2024
@renovate renovate bot closed this Oct 27, 2024
auto-merge was automatically disabled October 27, 2024 17:10

Pull request was closed

@renovate renovate bot deleted the renovate/ghcr.io-apollographql-router-1.x branch October 27, 2024 17:10
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 Oct 27, 2024
@renovate renovate bot reopened this Oct 27, 2024
@renovate renovate bot restored the renovate/ghcr.io-apollographql-router-1.x branch October 27, 2024 18:14
@renovate renovate bot enabled auto-merge October 27, 2024 18:14
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from 3523220 to 9cdf8be Compare October 27, 2024 18:14
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 - autoclosed Oct 30, 2024
@renovate renovate bot closed this Oct 30, 2024
auto-merge was automatically disabled October 30, 2024 05:17

Pull request was closed

@renovate renovate bot deleted the renovate/ghcr.io-apollographql-router-1.x branch October 30, 2024 05:17
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 Oct 30, 2024
@renovate renovate bot reopened this Oct 30, 2024
@renovate renovate bot restored the renovate/ghcr.io-apollographql-router-1.x branch October 30, 2024 06:48
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from 9cdf8be to 822f1d0 Compare October 30, 2024 06:48
@renovate renovate bot enabled auto-merge October 30, 2024 06:48
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from 822f1d0 to 23ab75d Compare October 31, 2024 02:13
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 - autoclosed Nov 2, 2024
@renovate renovate bot closed this Nov 2, 2024
auto-merge was automatically disabled November 2, 2024 00:36

Pull request was closed

@renovate renovate bot deleted the renovate/ghcr.io-apollographql-router-1.x branch November 2, 2024 00:36
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.0 Nov 2, 2024
@renovate renovate bot reopened this Nov 2, 2024
@renovate renovate bot restored the renovate/ghcr.io-apollographql-router-1.x branch November 2, 2024 04:18
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 Nov 13, 2024
@renovate renovate bot reopened this Nov 13, 2024
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from 2ee1f06 to 0fe577f Compare November 13, 2024 04:46
@renovate renovate bot enabled auto-merge November 13, 2024 07:38
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 - autoclosed Nov 25, 2024
@renovate renovate bot closed this Nov 25, 2024
auto-merge was automatically disabled November 25, 2024 23:55

Pull request was closed

@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 Nov 26, 2024
@renovate renovate bot reopened this Nov 26, 2024
@renovate renovate bot enabled auto-merge November 26, 2024 06:46
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from 0fe577f to c6acbb6 Compare November 27, 2024 19:55
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.57.1 chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 Nov 27, 2024
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 - autoclosed Nov 29, 2024
@renovate renovate bot closed this Nov 29, 2024
auto-merge was automatically disabled November 29, 2024 19:31

Pull request was closed

@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 Nov 30, 2024
@renovate renovate bot reopened this Nov 30, 2024
@renovate renovate bot enabled auto-merge November 30, 2024 03:56
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 - autoclosed Dec 2, 2024
@renovate renovate bot closed this Dec 2, 2024
auto-merge was automatically disabled December 2, 2024 00:46

Pull request was closed

@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 - autoclosed chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 Dec 2, 2024
@renovate renovate bot reopened this Dec 2, 2024
@renovate renovate bot enabled auto-merge December 2, 2024 12:42
@renovate renovate bot force-pushed the renovate/ghcr.io-apollographql-router-1.x branch from c6acbb6 to 2e6d210 Compare December 6, 2024 11:03
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.0 chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.1 Dec 6, 2024
@renovate renovate bot changed the title chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.1 chore(deps): update ghcr.io/apollographql/router docker tag to v1.58.1 - autoclosed Dec 8, 2024
@renovate renovate bot closed this Dec 8, 2024
auto-merge was automatically disabled December 8, 2024 17:24

Pull request was closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants