Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Add
apollo.router.pipelines
metrics (PR #6967)When the router reloads, either via schema change or config change, a new request pipeline is created.
Existing request pipelines are closed once their requests finish. However, this may not happen if there are ongoing long requests that do not finish, such as Subscriptions.
To enable debugging when request pipelines are being kept around, a new gauge metric has been added:
apollo.router.pipelines
- The number of request pipelines active in the routerschema.id
- The Apollo Studio schema hash associated with the pipeline.launch.id
- The Apollo Studio launch id associated with the pipeline (optional).config.hash
- The hash of the configurationBy @BrynCooke in #6967
Add
apollo.router.open_connections
metric (PR #7023)To help users to diagnose when connections are keeping pipelines hanging around, the following metric has been added:
apollo.router.open_connections
- The number of request pipelines active in the routerschema.id
- The Apollo Studio schema hash associated with the pipeline.launch.id
- The Apollo Studio launch id associated with the pipeline (optional).config.hash
- The hash of the configuration.server.address
- The address that the router is listening on.server.port
- The port that the router is listening on if not a unix socket.state
- Eitheractive
orterminating
.You can use this metric to monitor when connections are open via long running requests or keepalive messages.
By @BrynCooke in #7009
Add
batching.maximum_size
configuration option to limit maximum client batch size (PR #7005)Add an optional
maximum_size
parameter to the batching configuration.maximum_size
queries in the client batch.If the number of queries provided exceeds the maximum batch size, the entire batch fails with error code 422 (
Unprocessable Content
). For example:By @carodewig in #7005
🐛 Fixes
Use correct default values on omitted OTLP endpoints (PR #6931)
Previously, when the configuration didn't specify an OTLP endpoint, the Router would always default to
http://localhost:4318
. However, port4318
is the correct default only for the HTTP protocol, while port4317
should be used for gRPC.Additionally, all other telemetry defaults in the Router configuration consistently use
127.0.0.1
as the hostname rather thanlocalhost
.With this change, the Router now uses:
http://127.0.0.1:4317
as the default for gRPC protocolhttp://127.0.0.1:4318
as the default for HTTP protocolThis ensures protocol-appropriate port defaults and consistent hostname usage across all telemetry configurations.
By @IvanGoncharov in #6931
Separate entity keys and representation variables in entity cache key (Issue #6673)
This fix separates the entity keys and representation variable values in the cache key, to avoid issues with
@requires
for example.By @bnjjj in #6888