Repository navigation
[CDTOOL-1744] CLI support for routing configs - #1931
Conversation
56211f1 to
6aed881
Compare
Adds the `fastly routing-config` command family (create/describe/list/ delete/activate/deactivate, plus nested draft, version, path, and path rule subcommands) backed by the go-fastly domain-management routing-configs client. Also adds `--routing-config-id` / `--unset-routing-config-id` to `fastly domain update` to manage the domain-to-routing-config linkage, and documents all new commands
6aed881 to
3db04e3
Compare
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
5 open findings
A substantial new command surface area is being introduced here (routing-config + nested… · New The PR description says this adds--routing-config-id/--unset-routing-config-id, but the… · New The PR description says this adds--routing-config-id/--unset-routing-config-id, but the… · New These fields are treated as time-like values elsewhere in this PR (e.g., using.String()in… · New As in other outputs in this PR,UpdatedAtappears to be a time-like value where.String()is… · New
What changed in this PR
Adds CLI support for Fastly Domain Management routing configs, including routing-config CRUD/subcommands and domain↔routing-config association management.
Changes:
- Introduces
fastly routing-configcommand family with nesteddraft,version,path, andpath rulesubcommands. - Extends
fastly domain updatewith--routing-config-idsupport and documents new behavior in metadata. - Registers new commands in the CLI command registry and updates changelog/app metadata.
| File | Description |
|---|---|
| pkg/commands/routingconfig/root.go | Adds routing-config command root. |
| pkg/commands/routingconfig/doc.go | Package docs for routing-config commands. |
| pkg/commands/routingconfig/create.go | Implements routing-config create. |
| pkg/commands/routingconfig/describe.go | Implements routing-config describe/get. |
| pkg/commands/routingconfig/list.go | Implements routing-config list with filtering/sorting. |
| pkg/commands/routingconfig/delete.go | Implements routing-config delete/remove (with --force). |
| pkg/commands/routingconfig/activate.go | Implements routing-config activate (activate draft). |
| pkg/commands/routingconfig/deactivate.go | Implements routing-config deactivate. |
| pkg/commands/routingconfig/common.go | Adds summary/verbose output helpers for routing configs. |
| pkg/commands/routingconfig/draft/root.go | Adds routing-config draft subcommand root. |
| pkg/commands/routingconfig/draft/doc.go | Package docs for draft subcommands. |
| pkg/commands/routingconfig/draft/diff.go | Implements routing-config draft diff. |
| pkg/commands/routingconfig/draft/update.go | Implements routing-config draft update (comment). |
| pkg/commands/routingconfig/draft/delete.go | Implements routing-config draft delete/discard. |
| pkg/commands/routingconfig/version/root.go | Adds routing-config version subcommand root. |
| pkg/commands/routingconfig/version/doc.go | Package docs for version subcommands. |
| pkg/commands/routingconfig/version/list.go | Implements routing-config version list. |
| pkg/commands/routingconfig/version/activate.go | Implements routing-config version activate (reactivate). |
| pkg/commands/routingconfig/version/deleteinactive.go | Implements routing-config version delete-inactive. |
| pkg/commands/routingconfig/path/root.go | Adds routing-config path subcommand root. |
| pkg/commands/routingconfig/path/doc.go | Package docs for path subcommands. |
| pkg/commands/routingconfig/path/create.go | Implements routing-config path create. |
| pkg/commands/routingconfig/path/describe.go | Implements routing-config path describe/get. |
| pkg/commands/routingconfig/path/list.go | Implements routing-config path list with filtering/sorting. |
| pkg/commands/routingconfig/path/update.go | Implements routing-config path update. |
| pkg/commands/routingconfig/path/delete.go | Implements routing-config path delete/remove. |
| pkg/commands/routingconfig/path/common.go | Adds summary/verbose output helpers for paths. |
| pkg/commands/routingconfig/path/rule/root.go | Adds routing-config path rule subcommand root. |
| pkg/commands/routingconfig/path/rule/doc.go | Package docs for rule subcommands. |
| pkg/commands/routingconfig/path/rule/create.go | Implements routing-config path rule create/add (JSON file input). |
| pkg/commands/routingconfig/path/rule/describe.go | Implements routing-config path rule describe/get. |
| pkg/commands/routingconfig/path/rule/list.go | Implements routing-config path rule list. |
| pkg/commands/routingconfig/path/rule/update.go | Implements routing-config path rule update (JSON file input). |
| pkg/commands/routingconfig/path/rule/delete.go | Implements routing-config path rule delete/remove. |
| pkg/commands/routingconfig/path/rule/common.go | Adds summary/verbose output helpers for rules. |
| pkg/commands/domain/update.go | Adds --routing-config-id support to domain update and prints association in success output. |
| pkg/commands/domain/domain_test.go | Adds test cases covering new domain update routing-config behavior. |
| pkg/commands/commands.go | Registers routing-config command tree in CLI. |
| pkg/app/run_test.go | Updates top-level command list test to include routing-config. |
| pkg/app/metadata.json | Documents new routing-config command examples and new domain update examples. |
| CHANGELOG.md | Adds changelog entry for routing-config CLI support. |
🧠 Review effort: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
There was a problem hiding this comment.
Warning
Copilot couldn't run its full agentic review because it didn't start before the timeout. Make sure your repository has a runner available, or add a copilot-code-review.yml file specifying one with the runs-on attribute. See the docs for more details.
Copilot review overview
3 open findings
Using the magic string value'nil'to mean “clear the association” can be ambiguous (it makes… · New Using the magic string value'nil'to mean “clear the association” can be ambiguous (it makes… · New The error message should consistently useJSON(capitalized) and could be made slightly more… · New
5 resolved since last review
As in other outputs in this PR,UpdatedAtappears to be a time-like value where.String()is… These fields are treated as time-like values elsewhere in this PR (e.g., using.String()in… The PR description says this adds--routing-config-id/--unset-routing-config-id, but the… The PR description says this adds--routing-config-id/--unset-routing-config-id, but the… A substantial new command surface area is being introduced here (routing-config + nested…
🧠 Review effort: Lite
kpfleming
left a comment
There was a problem hiding this comment.
This looks good to me, other than the decision to use deploy or activate.


Change summary
Adds the
fastly routing-configcommand family (create/describe/list/ delete/activate/deactivate, plus nested draft, version, path, and path rule subcommands) backed by the go-fastly domain-management routing-configs client. Also adds--routing-config-idtofastly domain updateto manage the domain-to-routing-config linkage, and documents all new commandsAPI Spec
All Submissions:
New Feature Submissions: