Override Subgraph Config
Override Subgraph config
By default, we read the routing URL for each of your subgraphs from the router execution config. In most cases, no additional configuration is required.
However, if you do need to override a particular subgraph's routing URL (for example, to handle changing network topography), you can do so with the following config
New way
Using the new way, the entire subgraph config can be overridden.
The available options for subscription_protocol are ws, sse and sse_post.
The available options for subscription_websocket_subprotocol are graphql-ws, graphql-transport-ws and auto.
Old way (Will be deprecated soon)
Using the old way only the routing URL of the subgraph can be overridden.
A more practical example is for routers inside a Kubernetes cluster so they can use the cluster-local DNS name while keeping the public DNS name config in the control plane.
Keep in mind, that this will also modify the URLs in your router config.
Last updated