Usage
A proposal allows you to propose changes to a federated graph and review them
before applying.
Description
Thenpx wgc proposal create command allows you to create a new proposal for federated graph changes within the Cosmo platform. Proposals provide a way to suggest and review modifications to subgraphs within a federated graph before applying them. You can include existing subgraphs with schema changes, add new subgraphs, or remove existing subgraphs in a proposal.
Parameters
[name]: The name of the proposal you want to create. It should be a descriptive identifier for the proposal.
Options
-
-f, --federation-graph <federatedGraphName>(required): The name of the federated graph this proposal is for. -
-n, --namespace [namespace]: The namespace of the federated graph (Default: “default”). -
--subgraph <subgraph>: Specify a subgraph to include in the proposal with its updated schema. Can be specified multiple times for different subgraphs.- Format:
name:subgraph-name,schemaPath:path-to-schema - Example:
--subgraph name:products,schemaPath:./schemas/products.graphql
- Format:
-
--new-subgraph <subgraph>: Specify a new subgraph to add in the proposal. Can be specified multiple times.- Format:
name:subgraph-name,schemaPath:path-to-schema,labels:"key=value key=value" - Example:
--new-subgraph name:reviews,schemaPath:./schemas/reviews.graphql,labels:"team=B department=engineering"
- Format:
-
--deleted-subgraph <name>: Specify a subgraph to be deleted in the proposal. Can be specified multiple times.- Example:
--deleted-subgraph legacy-products
- Example:
At least one of
--subgraph, --new-subgraph, or --deleted-subgraph must be provided.