diff --git a/CHANGELOG.md b/CHANGELOG.md index 97058fbab9..5ae542a7e5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,342 @@ All notable changes to Router will be documented in this file. This project adheres to [Semantic Versioning v2.0.0](https://semver.org/spec/v2.0.0.html). +# [1.5.0] - 2022-12-06 +## ❗ BREAKING ❗ + +### Router debug Docker images now run under the control of heaptrack ([Issue #2135](https://github.com/apollographql/router/issues/2135)) + +From 1.5.0, our debug Docker image will invoke the router under the control of heaptrack. We are making this change to make it simple for users to investigate potential memory issues with the Router. + +Do not run debug images in performance sensitive contexts. The tracking of memory allocations will significantly impact performance. In general, the debug image should only be used in consultation with Apollo engineering and support. + +Look at our documentation for examples of how to use the image in either Docker or Kubernetes. + +By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2142 + +### Fix naming inconsistency of telemetry.metrics.common.attributes.router ([Issue #2076](https://github.com/apollographql/router/issues/2076)) + +Mirroring the rest of the config `router` should be `supergraph` + +```yaml +telemetry: + metrics: + common: + attributes: + router: # old +``` +becomes +```yaml +telemetry: + metrics: + common: + attributes: + supergraph: # new +``` + +By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2116 + +### CLI structure changes ([Issue #2123](https://github.com/apollographql/router/issues/2123)) + +There is now a separate subcommand for config related operations: +* `config` + * `schema` - Output the configuration schema + * `upgrade` - Upgrade the configuration with optional diff support. + +`router --schema` has been deprecated and users should move to `router config schema`. + +By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2116 + +## 🚀 Features + +### Add configuration for trace ID ([Issue #2080](https://github.com/apollographql/router/issues/2080)) + +Trace ids can be propagated directly from a request header: + +```yaml title="router.yaml" +telemetry: + tracing: + propagation: + # If you have your own way to generate a trace id and you want to pass it via a custom request header + request: + header_name: my-trace-id +``` +In addition, trace id can be exposed via a response header: +```yaml title="router.yaml" +telemetry: + tracing: + experimental_response_trace_id: + enabled: true # default: false + header_name: "my-trace-id" # default: "apollo-trace-id" +``` + +Using this configuration you will have a response header called `my-trace-id` containing the trace ID. It could help you to debug a specific query if you want to grep your log with this trace id to have more context. + +By [@bnjjj](https://github.com/bnjjj) in https://github.com/apollographql/router/pull/2131 + +### Add configuration for logging and add more logs ([Issue #1998](https://github.com/apollographql/router/issues/1998)) + +By default, logs do not contain request body, response body or headers. +It is now possible to conditionally add this information for debugging and audit purposes. +Here is an example how you can configure it: + +```yaml title="router.yaml" +telemetry: + experimental_logging: + format: json # By default it's "pretty" if you are in an interactive shell session + display_filename: true # Display filename where the log is coming from. Default: true + display_line_number: false # Display line number in the file where the log is coming from. Default: true + # If one of these headers matches we will log supergraph and subgraphs requests/responses + when_header: + - name: apollo-router-log-request + value: my_client + headers: true # default: false + body: true # default: false + # log request for all requests/responses headers coming from Iphones + - name: user-agent + match: ^Mozilla/5.0 (iPhone* + headers: true +``` + +By [@bnjjj](https://github.com/bnjjj) in https://github.com/apollographql/router/pull/2040 + +### Provide multi-arch (amd64/arm64) Docker images for the Router ([Issue #1932](https://github.com/apollographql/router/issues/1932)) + +From 1.5.0 our Docker images will be multi-arch. + +By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2138 + +### Add a supergraph configmap option to the helm chart ([PR #2119](https://github.com/apollographql/router/pull/2119)) + +Adds the capability to create a configmap containing your supergraph schema. Here's an example of how you could make use of this from your values.yaml and with the `helm` install command. + +```yaml +extraEnvVars: + - name: APOLLO_ROUTER_SUPERGRAPH_PATH + value: /data/supergraph-schema.graphql + +extraVolumeMounts: + - name: supergraph-schema + mountPath: /data + readOnly: true + +extraVolumes: + - name: supergraph-schema + configMap: + name: "{{ .Release.Name }}-supergraph" + items: + - key: supergraph-schema.graphql + path: supergraph-schema.graphql +``` + +With that values.yaml content, and with your supergraph schema in a file name supergraph-schema.graphql, you can execute: + +``` +helm upgrade --install --create-namespace --namespace router-test --set-file supergraphFile=supergraph-schema.graphql router-test oci://ghcr.io/apollographql/helm-charts/router --version 1.0.0-rc.9 --values values.yaml +``` + +By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2119 + +### Configuration upgrades ([Issue #2123](https://github.com/apollographql/router/issues/2123)) + +Occasionally we will make changes to the Router yaml configuration format. +When starting the Router, if the configuration can be upgraded, it will do so automatically and display a warning: + +``` +2022-11-22T14:01:46.884897Z WARN router configuration contains deprecated options: + + 1. telemetry.tracing.trace_config.attributes.router has been renamed to 'supergraph' for consistency + +These will become errors in the future. Run `router config upgrade ` to see a suggested upgraded configuration. +``` + +Note: If a configuration has errors after upgrading then the configuration will not be upgraded automatically. + +From the CLI users can run: +* `router config upgrade ` to output configuration that has been upgraded to match the latest config format. +* `router config upgrade --diff ` to output a diff e.g. +``` + telemetry: + apollo: + client_name_header: apollographql-client-name + metrics: + common: + attributes: +- router: ++ supergraph: + request: + header: + - named: "1" # foo +``` + +There are situations where comments and whitespace are not preserved. + +By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2116, https://github.com/apollographql/router/pull/2162 + +### *Experimental* 🥼 subgraph request retry ([Issue #338](https://github.com/apollographql/router/issues/338), [Issue #1956](https://github.com/apollographql/router/issues/1956)) + +Implements subgraph request retries, using Finagle's retry buckets algorithm: +- it defines a minimal number of retries per second (`min_per_sec`, default is 10 retries per second), to +bootstrap the system or for low traffic deployments +- for each successful request, we add a "token" to the bucket, those tokens expire after `ttl` (default: 10 seconds) +- the number of available additional retries is a part of the number of tokens, defined by `retry_percent` (default is 0.2) + +Request retries are disabled by default on mutations. + +This is activated in the `traffic_shaping` plugin, either globally or per subgraph: + +```yaml +traffic_shaping: + all: + experimental_retry: + min_per_sec: 10 + ttl: 10s + retry_percent: 0.2 + retry_mutations: false + subgraphs: + accounts: + experimental_retry: + min_per_sec: 20 +``` + +By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2006 and https://github.com/apollographql/router/pull/2160 + +### *Experimental* 🥼 Caching configuration ([Issue #2075](https://github.com/apollographql/router/issues/2075)) + +Split Redis cache configuration for APQ and query planning: + +```yaml +supergraph: + apq: + experimental_cache: + in_memory: + limit: 512 + redis: + urls: ["redis://..."] + query_planning: + experimental_cache: + in_memory: + limit: 512 + redis: + urls: ["redis://..."] +``` + +By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2155 + +### `@defer` Apollo tracing support ([Issue #1600](https://github.com/apollographql/router/issues/1600)) + +Added Apollo tracing support for queries that use `@defer`. You can now view traces in Apollo Studio as normal. + +By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2190 + +## 🐛 Fixes + +### Fix panic when dev mode enabled with empty config file ([Issue #2182](https://github.com/apollographql/router/issues/2182)) + +If you're running the Router with dev mode with an empty config file, it will no longer panic + +By [@bnjjj](https://github.com/bnjjj) in https://github.com/apollographql/router/pull/2195 + +### Fix missing apollo tracing variables ([Issue #2186](https://github.com/apollographql/router/issues/2186)) + +Send variable values had no effect. This is now fixed. +```yaml +telemetry: + apollo: + send_variable_values: all +``` + +By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2190 + + +### fix build_docker_image.sh script when using default repo ([PR #2163](https://github.com/apollographql/router/pull/2163)) + +Adding the `-r` flag recently broke the existing functionality to build from the default repo using `-b`. This fixes that. + +By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2163 + +### Improve errors when subgraph returns non-GraphQL response with a non-2xx status code ([Issue #2117](https://github.com/apollographql/router/issues/2117)) + +The error response will now contain the status code and status name. Example: `HTTP fetch failed from 'my-service': 401 Unauthorized` + +By [@col](https://github.com/col) in https://github.com/apollographql/router/pull/2118 + +### handle mutations containing `@defer` ([Issue #2099](https://github.com/apollographql/router/issues/2099)) + +The Router generates partial query shapes corresponding to the primary and deferred responses, +to validate the data sent back to the client. Those query shapes were invalid for mutations. + +By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2102 + +### *Experimental* 🥼 APQ and query planner Redis caching fixes ([PR #2176](https://github.com/apollographql/router/pull/2176)) + +* use a null byte as separator in Redis keys +* handle Redis connection errors +* mark APQ and query plan caching as license key functionality + +By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2176 + +## 🛠 Maintenance + +### Verify that deferred fragment acts as a boundary for nullability rules ([Issue #2169](https://github.com/apollographql/router/issues/2169)) + +Add a test to ensure that deferred fragments act as a boundary for nullability rules. + +By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2183 + +### Refactor APQ ([PR #2129](https://github.com/apollographql/router/pull/2129)) + +Remove duplicated code. + +By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2129 + +### Update apollo-rs ([PR #2177](https://github.com/apollographql/router/pull/2177)) + +Updates to new apollo-rs APIs, and fixes some potential panics on unexpected user input. + +By [@goto-bus-stop](https://github.com/goto-bus-stop) in https://github.com/apollographql/router/pull/2177 + +### Semi-automate the release ([PR #2202](https://github.com/apollographql/router/pull/2202)) + +Developers can now run: +`cargo xtask release prepare minor` + +To raise a release PR. + +By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2202 + + +### Fix webpki license check ([PR #2202](https://github.com/apollographql/router/pull/2202)) + +Fixed webpki license check. +Add missing Google Chromimum license. +By [@o0Ignition0o](https://github.com/o0Ignition0o) [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2202 + +## 📚 Documentation + +### Docs: Update cors match regex example ([Issue #2151](https://github.com/apollographql/router/issues/2151)) + +The docs CORS regex example now displays a working and safe way to allow `HTTPS` subdomains of `api.example.com`. + +By [@o0Ignition0o](https://github.com/o0Ignition0o) in https://github.com/apollographql/router/pull/2152 + + +### update documentation to reflect new examples structure ([Issue #2095](https://github.com/apollographql/router/issues/2095)) + +Updated the examples directory structure. This fixes the documentation links to the examples. It also makes clear that rhai subgraph fields are read-only, since they are shared resources. + +By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2133 + + +### Docs: Add a disclaimer for users who set up health-checks and prometheus endpoints in a containers environment ([Issue #2079](https://github.com/apollographql/router/issues/2079)) + +The health check and the prometheus endpoint listen to 127.0.0.1 by default. +While this is a safe default, it prevents other pods from performing healthchecks and scraping prometheus data. +This behavior and customization is now documented in the [health-checks](https://www.apollographql.com/docs/router/configuration/health-checks) and the [prometheus](https://www.apollographql.com/docs/router/configuration/metrics#using-prometheus) sections. + +By [@o0Ignition0o](https://github.com/o0Ignition0o) in https://github.com/apollographql/router/pull/2194 + + # [1.4.0] - 2022-11-15 ## 🚀 Features diff --git a/Cargo.lock b/Cargo.lock index 23f64378aa..fd006763c4 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -162,7 +162,7 @@ dependencies = [ [[package]] name = "apollo-router" -version = "1.4.0" +version = "1.5.0" dependencies = [ "access-json", "ansi_term", @@ -277,7 +277,7 @@ dependencies = [ [[package]] name = "apollo-router-benchmarks" -version = "1.4.0" +version = "1.5.0" dependencies = [ "apollo-router", "async-trait", @@ -293,7 +293,7 @@ dependencies = [ [[package]] name = "apollo-router-scaffold" -version = "1.4.0" +version = "1.5.0" dependencies = [ "anyhow", "cargo-scaffold", diff --git a/NEXT_CHANGELOG.md b/NEXT_CHANGELOG.md index eba01bf318..0ed480a744 100644 --- a/NEXT_CHANGELOG.md +++ b/NEXT_CHANGELOG.md @@ -13,6 +13,7 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm ## 🐛 Fixes ## 🛠 Maintenance ## 📚 Documentation +## 🥼 Experimental ## Example section entry format @@ -24,328 +25,3 @@ By [@USERNAME](https://github.com/USERNAME) in https://github.com/apollographql/ --> # [x.x.x] (unreleased) - 2022-mm-dd -## ❗ BREAKING ❗ - -### Router debug Docker images now run under the control of heaptrack ([Issue #2135](https://github.com/apollographql/router/issues/2135)) - -From the next release, our debug Docker image will invoke the router under the control of heaptrack. We are making this change to make it simple for users to investigate potential memory issues with the router. - -Do not run debug images in performance sensitive contexts. The tracking of memory allocations will significantly impact performance. In general, the debug image should only be used in consultation with Apollo engineering and support. - -Look at our documentation for examples of how to use the image in either Docker or Kubernetes. - -By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2142 - -### Fix naming inconsistency of telemetry.metrics.common.attributes.router ([Issue #2076](https://github.com/apollographql/router/issues/2076)) - -Mirroring the rest of the config `router` should be `supergraph` - -```yaml -telemetry: - metrics: - common: - attributes: - router: # old -``` -becomes -```yaml -telemetry: - metrics: - common: - attributes: - supergraph: # new -``` - -By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2116 - -### CLI structure changes ([Issue #2123](https://github.com/apollographql/router/issues/2123)) - -As the Router gains functionality the limitations of the current CLI structure are becoming apparent. - -There is now a separate subcommand for config related operations: -* `config` - * `schema` - Output the configuration schema - * `upgrade` - Upgrade the configuration with optional diff support. - -`router --schema` has been deprecated and users should move to `router config schema`. - -## 🚀 Features - -### Add configuration for trace ID ([Issue #2080](https://github.com/apollographql/router/issues/2080)) - -If you want to expose in response headers the generated trace ID or the one you provided using propagation headers you can use this configuration: - -```yaml title="router.yaml" -telemetry: - tracing: - experimental_response_trace_id: - enabled: true # default: false - header_name: "my-trace-id" # default: "apollo-trace-id" - propagation: - # If you have your own way to generate a trace id and you want to pass it via a custom request header - request: - header_name: my-trace-id -``` - -Using this configuration you will have a response header called `my-trace-id` containing the trace ID. It could help you to debug a specific query if you want to grep your log with this trace id to have more context. - -By [@bnjjj](https://github.com/bnjjj) in https://github.com/apollographql/router/pull/2131 - -### Add configuration for logging and add more logs - -By default some logs containing sensible data (like request body, response body, headers) are not displayed even if we set the right log level. -For example if you need to display raw responses from one of your subgraph it won't be displayed by default. To enable them you have to configure it thanks to the `when_header` setting in the new section `experimental_logging`. It let's you set different headers to enable more logs (request/response headers/body for supergraph and subgraphs) when the request contains these headers with corresponding values/regex. -Here is an example how you can configure it: - -```yaml title="router.yaml" -telemetry: - experimental_logging: - format: json # By default it's "pretty" if you are in an interactive shell session - display_filename: true # Display filename where the log is coming from. Default: true - display_line_number: false # Display line number in the file where the log is coming from. Default: true - # If one of these headers matches we will log supergraph and subgraphs requests/responses - when_header: - - name: apollo-router-log-request - value: my_client - headers: true # default: false - body: true # default: false - # log request for all requests/responses headers coming from Iphones - - name: user-agent - match: ^Mozilla/5.0 (iPhone* - headers: true -``` - -### Provide multi-arch (amd64/arm64) Docker images for the Router ([Issue #1932](https://github.com/apollographql/router/issues/1932)) - -From the next release, our Docker images will be multi-arch. - -By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2138 - -### Add a supergraph configmap option to the helm chart ([PR #2119](https://github.com/apollographql/router/pull/2119)) - -Adds the capability to create a configmap containing your supergraph schema. Here's an example of how you could make use of this from your values.yaml and with the `helm` install command. - -```yaml -extraEnvVars: - - name: APOLLO_ROUTER_SUPERGRAPH_PATH - value: /data/supergraph-schema.graphql - -extraVolumeMounts: - - name: supergraph-schema - mountPath: /data - readOnly: true - -extraVolumes: - - name: supergraph-schema - configMap: - name: "{{ .Release.Name }}-supergraph" - items: - - key: supergraph-schema.graphql - path: supergraph-schema.graphql -``` - -With that values.yaml content, and with your supergraph schema in a file name supergraph-schema.graphql, you can execute: - -``` -helm upgrade --install --create-namespace --namespace router-test --set-file supergraphFile=supergraph-schema.graphql router-test oci://ghcr.io/apollographql/helm-charts/router --version 1.0.0-rc.9 --values values.yaml -``` - -By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2119 - -### Configuration upgrades ([Issue #2123](https://github.com/apollographql/router/issues/2123)) - -Occasionally we will make changes to the Router yaml configuration format. -When starting the Router if the configuration can be upgraded it will do so automatically and display a warning: - -``` -2022-11-22T14:01:46.884897Z WARN router configuration contains deprecated options: - - 1. telemetry.tracing.trace_config.attributes.router has been renamed to 'supergraph' for consistency - -These will become errors in the future. Run `router config upgrade ` to see a suggested upgraded configuration. -``` - -Note: If a configuration has errors after upgrading then the configuration will not be upgraded automatically. - -From the CLI users can run: -* `router config upgrade ` to output configuration that has been upgraded to match the latest config format. -* `router config upgrade --diff ` to output a diff e.g. -``` - telemetry: - apollo: - client_name_header: apollographql-client-name - metrics: - common: - attributes: -- router: -+ supergraph: - request: - header: - - named: "1" # foo -``` - -There are situations where comments and whitespace are not preserved. This may be improved in future. - -By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2116, https://github.com/apollographql/router/pull/2162 - -### *Experimental* 🥼 subgraph request retry ([Issue #338](https://github.com/apollographql/router/issues/338), [Issue #1956](https://github.com/apollographql/router/issues/1956)) - -Implements subgraph request retries, using Finagle's retry buckets algorithm: -- it defines a minimal number of retries per second (`min_per_sec`, default is 10 retries per second), to -bootstrap the system or for low traffic deployments -- for each successful request, we add a "token" to the bucket, those tokens expire after `ttl` (default: 10 seconds) -- the number of available additional retries is a part of the number of tokens, defined by `retry_percent` (default is 0.2) - -Request retries are disabled by default on mutations. - -This is activated in the `traffic_shaping` plugin, either globally or per subgraph: - -```yaml -traffic_shaping: - all: - experimental_retry: - min_per_sec: 10 - ttl: 10s - retry_percent: 0.2 - retry_mutations: false - subgraphs: - accounts: - experimental_retry: - min_per_sec: 20 -``` - -By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2006 and https://github.com/apollographql/router/pull/2160 - -### *Experimental* 🥼 Caching configuration ([Issue #2075](https://github.com/apollographql/router/issues/2075)) - -Split Redis cache configuration for APQ and query planning: - -```yaml -supergraph: - apq: - experimental_cache: - in_memory: - limit: 512 - redis: - urls: ["redis://..."] - query_planning: - experimental_cache: - in_memory: - limit: 512 - redis: - urls: ["redis://..."] -``` - -By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2155 - -### `@defer` Apollo tracing support ([Issue #1600](https://github.com/apollographql/router/issues/1600)) - -Added Apollo tracing support for queries that use `@defer`. You can now view traces in Apollo Studio as normal. - -By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2190 - -## 🐛 Fixes - -### Fix panic when dev mode enabled with empty config file ([Issue #2182](https://github.com/apollographql/router/issues/2182)) - -If you're running the Router with dev mode with an empty config file, it will no longer panic - -By [@bnjjj](https://github.com/bnjjj) in https://github.com/apollographql/router/pull/2195 - -### Fix missing apollo tracing variables ([Issue #2186](https://github.com/apollographql/router/issues/2186)) - -Send variable values had no effect. This is now fixed. -```yaml -telemetry: - apollo: - send_variable_values: all -``` - -By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2190 - - -### fix build_docker_image.sh script when using default repo ([PR #2163](https://github.com/apollographql/router/pull/2163)) - -Adding the `-r` flag recently broke the existing functionality to build from the default repo using `-b`. This fixes that. - -By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2163 - -### Improve errors when subgraph returns non-GraphQL response with a non-2xx status code ([Issue #2117](https://github.com/apollographql/router/issues/2117)) - -The error response will now contain the status code and status name. Example: `HTTP fetch failed from 'my-service': 401 Unauthorized` - -By [@col](https://github.com/col) in https://github.com/apollographql/router/pull/2118 - -### handle mutations containing @defer ([Issue #2099](https://github.com/apollographql/router/issues/2099)) - -The Router generates partial query shapes corresponding to the primary and deferred responses, -to validate the data sent back to the client. Those query shapes were invalid for mutations. - -By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2102 - -### *Experimental* 🥼 APQ and query planner Redis caching fixes ([PR #2176](https://github.com/apollographql/router/pull/2176)) - -* use a null byte as separator in Redis keys -* handle Redis connection errors -* mark APQ and query plan caching as license key functionality - -By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2176 - -## 🛠 Maintenance - -### Verify that deferred fragment acts as a boundary for nullability rules ([Issue #2169](https://github.com/apollographql/router/issues/2169)) - -Add a test to ensure that deferred fragments act as a boundary for nullability rules. - -By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2183 - -### Refactor APQ ([PR #2129](https://github.com/apollographql/router/pull/2129)) - -Remove duplicated code. - -By [@Geal](https://github.com/Geal) in https://github.com/apollographql/router/pull/2129 - -### Update apollo-rs ([PR #2177](https://github.com/apollographql/router/pull/2177)) - -Updates to new apollo-rs APIs, and fixes some potential panics on unexpected user input. - -By [@goto-bus-stop](https://github.com/goto-bus-stop) in https://github.com/apollographql/router/pull/2177 - -### Semi-automate the release ([PR #2202](https://github.com/apollographql/router/pull/2202)) - -Developers can now run: -`cargo xtask release prepare minor` - -To raise a release PR. - -By [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2202 - - -### Fix webpki license check ([PR #2202](https://github.com/apollographql/router/pull/2202)) - -There were issues with webpki license checks. This also meant that we were missing the Google Chromimum license which has als been fixed. -By [@o0Ignition0o](https://github.com/o0Ignition0o) [@bryncooke](https://github.com/bryncooke) in https://github.com/apollographql/router/pull/2202 - -## 📚 Documentation - -### Docs: Update cors match regex example ([Issue #2151](https://github.com/apollographql/router/issues/2151)) - -The docs CORS regex example now displays a working and safe way to allow `HTTPS` subdomains of `api.example.com`. - -By [@o0Ignition0o](https://github.com/o0Ignition0o) in https://github.com/apollographql/router/pull/2152 - - -### update documentation to reflect new examples structure ([Issue #2095](https://github.com/apollographql/router/issues/2095)) - -We recently updated the examples directory structure. This fixes the documentation links to the examples. It also makes clear that rhai subgraph fields are read-only, since they are shared resources. - -By [@garypen](https://github.com/garypen) in https://github.com/apollographql/router/pull/2133 - - -### Docs: Add a disclaimer for users who set up health-checks and prometheus endpoints in a containers environment ([Issue #2079](https://github.com/apollographql/router/issues/2079)) - -The health check and the prometheus endpoint listen to 127.0.0.1 by default. -While this is a safe default, it prevents other pods from performing healthchecks and scraping prometheus data. -This behavior and customization is now documented in the [health-checks](https://www.apollographql.com/docs/router/configuration/health-checks) and the [prometheus](https://www.apollographql.com/docs/router/configuration/metrics#using-prometheus) sections. - -By [@o0Ignition0o](https://github.com/o0Ignition0o) in https://github.com/apollographql/router/pull/2194 diff --git a/apollo-router-benchmarks/Cargo.toml b/apollo-router-benchmarks/Cargo.toml index 6deedfdb8d..49e47e1ed2 100644 --- a/apollo-router-benchmarks/Cargo.toml +++ b/apollo-router-benchmarks/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "apollo-router-benchmarks" -version = "1.4.0" +version = "1.5.0" authors = ["Apollo Graph, Inc. "] edition = "2021" license = "LicenseRef-ELv2" diff --git a/apollo-router-scaffold/Cargo.toml b/apollo-router-scaffold/Cargo.toml index 2c9cf1af01..e8d9b9061e 100644 --- a/apollo-router-scaffold/Cargo.toml +++ b/apollo-router-scaffold/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "apollo-router-scaffold" -version = "1.4.0" +version = "1.5.0" authors = ["Apollo Graph, Inc. "] edition = "2021" license = "LicenseRef-ELv2" diff --git a/apollo-router/Cargo.toml b/apollo-router/Cargo.toml index 4aa791b8cf..84f9f5569c 100644 --- a/apollo-router/Cargo.toml +++ b/apollo-router/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "apollo-router" -version = "1.4.0" +version = "1.5.0" authors = ["Apollo Graph, Inc. "] repository = "https://github.com/apollographql/router/" documentation = "https://www.apollographql.com/docs/router/" diff --git a/dockerfiles/tracing/docker-compose.datadog.yml b/dockerfiles/tracing/docker-compose.datadog.yml index 7dd43800a4..c2fe3f7100 100644 --- a/dockerfiles/tracing/docker-compose.datadog.yml +++ b/dockerfiles/tracing/docker-compose.datadog.yml @@ -3,7 +3,7 @@ services: apollo-router: container_name: apollo-router - image: ghcr.io/apollographql/router:v1.4.0 + image: ghcr.io/apollographql/router:v1.5.0 volumes: - ./supergraph.graphql:/etc/config/supergraph.graphql - ./router/datadog.router.yaml:/etc/config/configuration.yaml diff --git a/dockerfiles/tracing/docker-compose.jaeger.yml b/dockerfiles/tracing/docker-compose.jaeger.yml index 82cb7ee881..4ff6a379e8 100644 --- a/dockerfiles/tracing/docker-compose.jaeger.yml +++ b/dockerfiles/tracing/docker-compose.jaeger.yml @@ -4,7 +4,7 @@ services: apollo-router: container_name: apollo-router #build: ./router - image: ghcr.io/apollographql/router:v1.4.0 + image: ghcr.io/apollographql/router:v1.5.0 volumes: - ./supergraph.graphql:/etc/config/supergraph.graphql - ./router/jaeger.router.yaml:/etc/config/configuration.yaml diff --git a/dockerfiles/tracing/docker-compose.zipkin.yml b/dockerfiles/tracing/docker-compose.zipkin.yml index aee074d72c..098a9f43a3 100644 --- a/dockerfiles/tracing/docker-compose.zipkin.yml +++ b/dockerfiles/tracing/docker-compose.zipkin.yml @@ -4,7 +4,7 @@ services: apollo-router: container_name: apollo-router build: ./router - image: ghcr.io/apollographql/router:v1.4.0 + image: ghcr.io/apollographql/router:v1.5.0 volumes: - ./supergraph.graphql:/etc/config/supergraph.graphql - ./router/zipkin.router.yaml:/etc/config/configuration.yaml diff --git a/docs/source/containerization/docker.mdx b/docs/source/containerization/docker.mdx index 530246f380..9314399b5c 100644 --- a/docs/source/containerization/docker.mdx +++ b/docs/source/containerization/docker.mdx @@ -11,7 +11,7 @@ The default behaviour of the router images is suitable for a quickstart or devel Note: The [docker documentation](https://docs.docker.com/engine/reference/run/) for the run command may be helpful when reading through the examples. -Note: The exact image version to use is your choice depending on which release you wish to use. In the following examples, replace `` with your chosen version. e.g.: `v1.4.0` +Note: The exact image version to use is your choice depending on which release you wish to use. In the following examples, replace `` with your chosen version. e.g.: `v1.5.0` ## Override the configuration diff --git a/docs/source/containerization/kubernetes.mdx b/docs/source/containerization/kubernetes.mdx index 3be252c9e0..537015a552 100644 --- a/docs/source/containerization/kubernetes.mdx +++ b/docs/source/containerization/kubernetes.mdx @@ -13,7 +13,7 @@ import { Link } from 'gatsby'; [Helm](https://helm.sh) is the package manager for kubernetes. -There is a complete [helm chart definition](https://github.com/apollographql/router/tree/v1.4.0/helm/chart/router) in the repo which illustrates how to use helm to deploy the router in kubernetes. +There is a complete [helm chart definition](https://github.com/apollographql/router/tree/v1.5.0/helm/chart/router) in the repo which illustrates how to use helm to deploy the router in kubernetes. In both the following examples, we are using helm to install the router: - into namespace "router-deploy" (create namespace if it doesn't exist) @@ -82,7 +82,7 @@ metadata: app.kubernetes.io/version: "v1.4.0" app.kubernetes.io/managed-by: Helm data: - managedFederationApiKey: "UkVEQUNURUQ=" + managedFederationApiKey: "IlJFREFDVEVEIg==" --- # Source: router/templates/configmap.yaml apiVersion: v1 @@ -148,7 +148,7 @@ metadata: app.kubernetes.io/instance: release-name app.kubernetes.io/version: "v1.4.0" app.kubernetes.io/managed-by: Helm - + annotations: prometheus.io/path: /metrics prometheus.io/port: "9090" @@ -186,7 +186,7 @@ spec: key: managedFederationApiKey optional: true - name: APOLLO_GRAPH_REF - value: REDACTED + value: "REDACTED" ports: - name: http containerPort: 80 diff --git a/helm/chart/router/Chart.yaml b/helm/chart/router/Chart.yaml index 13da0d065c..91cd86e321 100644 --- a/helm/chart/router/Chart.yaml +++ b/helm/chart/router/Chart.yaml @@ -19,10 +19,10 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 1.0.0-rc.8 +version: 1.0.0-rc.9 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. # It is recommended to use it with quotes. -appVersion: "v1.4.0" +appVersion: "v1.5.0" diff --git a/helm/chart/router/README.md b/helm/chart/router/README.md index 201e8645e5..e07074daf9 100644 --- a/helm/chart/router/README.md +++ b/helm/chart/router/README.md @@ -80,6 +80,7 @@ helm show values oci://ghcr.io/apollographql/helm-charts/router | serviceAccount.name | string | `""` | | | serviceMonitor.enabled | bool | `false` | | | serviceentry.enabled | bool | `false` | | +| supergraphFile | string | `nil` | | | tolerations | list | `[]` | | | virtualservice.enabled | bool | `false` | | diff --git a/scripts/install.sh b/scripts/install.sh index c28759d6c5..297d3e3713 100755 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -11,7 +11,7 @@ BINARY_DOWNLOAD_PREFIX="https://github.com/apollographql/router/releases/downloa # Router version defined in apollo-router's Cargo.toml # Note: Change this line manually during the release steps. -PACKAGE_VERSION="v1.4.0" +PACKAGE_VERSION="v1.5.0" download_binary() { downloader --check