{Network} az network route-table route: Add support for VirtualApplianceEcmp next hop type - #33493
Open
Jian Hui (huiii99) wants to merge 3 commits into
Open
Conversation
❌AzureCLI-FullTest
|
|
| rule | cmd_name | rule_message | suggest_message |
|---|---|---|---|
| network route-table route create | cmd network route-table route create added parameter next_hop |
||
| network route-table route create | cmd network route-table route create update parameter next_hop_type: updated property choices from ['Internet', 'None', 'VirtualAppliance', 'VirtualNetworkGateway', 'VnetLocal'] to ['Internet', 'None', 'VirtualAppliance', 'VirtualApplianceEcmp', 'VirtualNetworkGateway', 'VnetLocal'] |
||
| network route-table route list | cmd network route-table route list added parameter pagination_limit |
||
| network route-table route list | cmd network route-table route list added parameter pagination_token |
||
| network route-table route update | cmd network route-table route update added parameter next_hop |
||
| network route-table route update | cmd network route-table route update update parameter next_hop_type: updated property choices from ['Internet', 'None', 'VirtualAppliance', 'VirtualNetworkGateway', 'VnetLocal'] to ['Internet', 'None', 'VirtualAppliance', 'VirtualApplianceEcmp', 'VirtualNetworkGateway', 'VnetLocal'] |
microsoft-github-policy-service
Bot
requested review from
Yu Chen (jsntcy),
kai ru (kairu-ms) and
Yong Zhang (yonzhan)
June 4, 2026 04:18
Collaborator
|
Network |
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 3 pipeline(s). |
Member
|
/azp run |
|
Azure Pipelines: Successfully started running 3 pipeline(s). |
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the network route-table route AAZ commands to support the new VirtualApplianceEcmp next hop type (API version 2025-07-01), including accepting ECMP next-hop IP address arrays on create/update and surfacing the nextHop structure in command outputs. It also adds a scenario test + recordings for the ECMP route workflow.
Changes:
- Add
VirtualApplianceEcmpto--next-hop-typechoices and introduce--next-hop next-hop-ip-addresses=...for ECMP route creation/update. - Update show/list/wait output schemas to include the
nextHop.nextHopIpAddressesstructure and bump route API version usage to2025-07-01. - Add a new scenario test and recordings for ECMP route create/show/list/update/delete flows.
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/azure-cli/azure/cli/command_modules/network/tests/latest/test_network_commands.py | Adds a new scenario test covering ECMP route create/show/list/update. |
| src/azure-cli/azure/cli/command_modules/network/tests/latest/recordings/test_network_route_table_operation.yaml | Updates existing route-table recording requests to use API version 2025-07-01. |
| src/azure-cli/azure/cli/command_modules/network/tests/latest/recordings/test_network_route_table_ecmp_route.yaml | Adds a new recording for the ECMP route scenario test. |
| src/azure-cli/azure/cli/command_modules/network/aaz/latest/network/route_table/route/_create.py | Adds ECMP next hop support to route create and updates schemas/version. |
| src/azure-cli/azure/cli/command_modules/network/aaz/latest/network/route_table/route/_update.py | Adds ECMP next hop support to route update and refactors common read schema. |
| src/azure-cli/azure/cli/command_modules/network/aaz/latest/network/route_table/route/_show.py | Updates show schema/version to include ECMP nextHop shape. |
| src/azure-cli/azure/cli/command_modules/network/aaz/latest/network/route_table/route/_list.py | Enables pagination, updates list schema/version to include ECMP nextHop shape. |
| src/azure-cli/azure/cli/command_modules/network/aaz/latest/network/route_table/route/_delete.py | Bumps delete operation API version to 2025-07-01. |
| src/azure-cli/azure/cli/command_modules/network/aaz/latest/network/route_table/route/_wait.py | Bumps wait operation API version and updates schema to include ECMP nextHop shape. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Comment on lines
180
to
190
| properties = cls._schema_on_200.value.Element.properties | ||
| properties.address_prefix = AAZStrType( | ||
| serialized_name="addressPrefix", | ||
| ) | ||
| properties.has_bgp_override = AAZBoolType( | ||
| serialized_name="hasBgpOverride", | ||
| flags={"read_only": True}, | ||
| ) | ||
| properties.next_hop = AAZObjectType( | ||
| serialized_name="nextHop", | ||
| ) |
Comment on lines
+5509
to
+5513
| self.cmd('network route-table route list -g {rg} --route-table-name {table}', | ||
| checks=[ | ||
| self.check('length(@)', 1), | ||
| self.check('[0].nextHopType', 'VirtualApplianceEcmp') | ||
| ]) |
Comment on lines
+104
to
+107
| next_hop_ip_addresses = cls._args_schema.next_hop.next_hop_ip_addresses | ||
| next_hop_ip_addresses.Element = AAZStrArg( | ||
| nullable=True, | ||
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 PR Validation —⚠️ Review suggested
Related command
az network route-table route create/update/show/listDescription
az network route-table route create/update: Add--next-hop-type VirtualApplianceEcmpand--next-hop next-hop-ip-addressesparameter for ECMP load-balancing across multiple virtual appliance instances.az network route-table route show/list: DisplaynextHop.nextHopIpAddressesarray in output for ECMP routes.resolve: #32873
aaz: Azure/aaz#1022
Testing Guide
azdev test test_network_route_table_ecmp_route --liveHistory Notes
This checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.