Our solution
Feature flags for safer GraphQL schema delivery
Feature subgraphs are alternative implementations of base subgraphs in your federated graph. When a feature flag is active for a request, Cosmo Router uses the feature subgraph instead of the base subgraph for that request. Teams can roll out schema changes by header, JWT claim, or cookie without deploying a new router version.
How it works
Create a feature subgraph as an alternative implementation of a base subgraph.
Create a feature flag that activates the feature subgraph for matching requests.
Define activation criteria using headers, JWT claims, or cookies.
For matching requests, Cosmo Router uses the graph composition with the feature subgraph. Other requests continue using the base composition.
Enable or disable the flag at any time. Changes propagate in under one second without deploying new router versions.
Schema-aware. Federation-native. Without deploying new router versions.

