Skip to content

[ACR] BREAKING CHANGE: connected-registry: commands update - #28682

Draft
Rodrigo Mendoza (rosanch) wants to merge 10 commits into
Azure:devfrom
rosanch:roy/onprem
Draft

Rodrigo Mendoza (rosanch) wants to merge 10 commits into
Azure:devfrom
rosanch:roy/onprem

Conversation

@rosanch

@rosanch Rodrigo Mendoza (rosanch) commented Apr 2, 2024 •

Copy link
Copy Markdown
Contributor

Related command
az acr connected-registry create/update/install

Description
Minor updates on ACR connected registry commands:

  • install sub-group and commands are removed
  • create: mode default value change to readOnly
  • create: if data endpoint disable ask for enabling it instead of throwing an error.
  • update: change command type to use generic_update_command instead

Testing Guide

  1. Create connected-registry in an ACR without data-endpoint enabled
    1.1 respond no
    1.2 try again respond yes
  2. create another connected-registry in the same ACR
  3. update any connected-registry

History Notes

[ACR] BREAKING CHANGE: az acr connected-registry install: Group and sub-commands removed
[ACR] BREAKING CHANGE: az acr connected-registry create: Mode default value change from ReadWrite to ReadOnly
[ACR] az acr connected-registry create: If data-endpoint disabled ask for confirmation to enable it instead of throwing an error


This checklist is used to make sure that common guidelines for a pull request are followed.

@azure-client-tools-bot-prd

azure-client-tools-bot-prd Bot commented Apr 2, 2024 •

Copy link
Copy Markdown
❌AzureCLI-FullTest
❌acr
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
❌latest
❌3.11
Type Test Case Error Message Line
Failed test_acr_connectedregistry The error message is too long, please check the pipeline log for details. azure/cli/command_modules/acr/tests/latest/test_acr_connectedregistry_commands.py:10
❌3.9
Type Test Case Error Message Line
Failed test_acr_connectedregistry The error message is too long, please check the pipeline log for details. azure/cli/command_modules/acr/tests/latest/test_acr_connectedregistry_commands.py:10
️✔️acs
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️advisor
️✔️latest
️✔️3.11
️✔️3.9
️✔️ams
️✔️latest
️✔️3.11
️✔️3.9
️✔️apim
️✔️latest
️✔️3.11
️✔️3.9
️✔️appconfig
️✔️latest
️✔️3.11
️✔️3.9
️✔️appservice
️✔️latest
️✔️3.11
️✔️3.9
️✔️aro
️✔️latest
️✔️3.11
️✔️3.9
️✔️backup
️✔️latest
️✔️3.11
️✔️3.9
️✔️batch
️✔️latest
️✔️3.11
️✔️3.9
️✔️batchai
️✔️latest
️✔️3.11
️✔️3.9
️✔️billing
️✔️latest
️✔️3.11
️✔️3.9
️✔️botservice
️✔️latest
️✔️3.11
️✔️3.9
️✔️cdn
️✔️latest
️✔️3.11
️✔️3.9
️✔️cloud
️✔️latest
️✔️3.11
️✔️3.9
️✔️cognitiveservices
️✔️latest
️✔️3.11
️✔️3.9
️✔️config
️✔️latest
️✔️3.11
️✔️3.9
️✔️configure
️✔️latest
️✔️3.11
️✔️3.9
️✔️consumption
️✔️latest
️✔️3.11
️✔️3.9
️✔️container
️✔️latest
️✔️3.11
️✔️3.9
️✔️containerapp
️✔️latest
️✔️3.11
️✔️3.9
️✔️core
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️cosmosdb
️✔️latest
️✔️3.11
️✔️3.9
️✔️databoxedge
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️dla
️✔️latest
️✔️3.11
️✔️3.9
️✔️dls
️✔️latest
️✔️3.11
️✔️3.9
️✔️dms
️✔️latest
️✔️3.11
️✔️3.9
️✔️eventgrid
️✔️latest
️✔️3.11
️✔️3.9
️✔️eventhubs
️✔️latest
️✔️3.11
️✔️3.9
️✔️feedback
️✔️latest
️✔️3.11
️✔️3.9
️✔️find
️✔️latest
️✔️3.11
️✔️3.9
️✔️hdinsight
️✔️latest
️✔️3.11
️✔️3.9
️✔️identity
️✔️latest
️✔️3.11
️✔️3.9
️✔️iot
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️keyvault
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️kusto
️✔️latest
️✔️3.11
️✔️3.9
️✔️lab
️✔️latest
️✔️3.11
️✔️3.9
️✔️managedservices
️✔️latest
️✔️3.11
️✔️3.9
️✔️maps
️✔️latest
️✔️3.11
️✔️3.9
️✔️marketplaceordering
️✔️latest
️✔️3.11
️✔️3.9
️✔️monitor
️✔️latest
️✔️3.11
️✔️3.9
️✔️mysql
️✔️latest
️✔️3.11
️✔️3.9
️✔️netappfiles
️✔️latest
️✔️3.11
️✔️3.9
️✔️network
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️policyinsights
️✔️latest
️✔️3.11
️✔️3.9
️✔️privatedns
️✔️latest
️✔️3.11
️✔️3.9
️✔️profile
️✔️latest
️✔️3.11
️✔️3.9
️✔️rdbms
️✔️latest
️✔️3.11
️✔️3.9
️✔️redis
️✔️latest
️✔️3.11
️✔️3.9
️✔️relay
️✔️latest
️✔️3.11
️✔️3.9
️✔️resource
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️role
️✔️latest
️✔️3.11
️✔️3.9
️✔️search
️✔️latest
️✔️3.11
️✔️3.9
️✔️security
️✔️latest
️✔️3.11
️✔️3.9
️✔️servicebus
️✔️latest
️✔️3.11
️✔️3.9
️✔️serviceconnector
️✔️latest
️✔️3.11
️✔️3.9
️✔️servicefabric
️✔️latest
️✔️3.11
️✔️3.9
️✔️signalr
️✔️latest
️✔️3.11
️✔️3.9
️✔️sql
️✔️latest
️✔️3.11
️✔️3.9
️✔️sqlvm
️✔️latest
️✔️3.11
️✔️3.9
️✔️storage
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️synapse
️✔️latest
️✔️3.11
️✔️3.9
️✔️telemetry
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9
️✔️util
️✔️latest
️✔️3.11
️✔️3.9
️✔️vm
️✔️2018-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2019-03-01-hybrid
️✔️3.11
️✔️3.9
️✔️2020-09-01-hybrid
️✔️3.11
️✔️3.9
️✔️latest
️✔️3.11
️✔️3.9

@azure-client-tools-bot-prd

azure-client-tools-bot-prd Bot commented Apr 2, 2024 •

Copy link
Copy Markdown
❌AzureCLI-BreakingChangeTest
❌acr
rule cmd_name rule_message suggest_message
❌ 1010 - ParaPropUpdate acr connected-registry create cmd acr connected-registry create update parameter mode: updated property default from ReadWrite to ReadOnly please change property default from ReadOnly to ReadWrite for parameter mode of cmd acr connected-registry create
❌ 1012 - SubgroupRemove acr connected-registry install sub group acr connected-registry install removed please confirm sub group acr connected-registry install removed
❌ 1002 - CmdRemove acr connected-registry repo cmd acr connected-registry repo removed please confirm cmd acr connected-registry repo removed
⚠️ 1006 - ParaAdd acr connected-registry create cmd acr connected-registry create added parameter yes
⚠️ 1006 - ParaAdd acr connected-registry update cmd acr connected-registry update added parameter force_string
⚠️ 1006 - ParaAdd acr connected-registry update cmd acr connected-registry update added parameter properties_to_add
⚠️ 1006 - ParaAdd acr connected-registry update cmd acr connected-registry update added parameter properties_to_remove
⚠️ 1006 - ParaAdd acr connected-registry update cmd acr connected-registry update added parameter properties_to_set

@yonzhan

Copy link
Copy Markdown
Collaborator

ACR

@rosanch

Copy link
Copy Markdown
Contributor Author

Xing Zhou (@zhoxing-ms) I see coverage failing saying we don't have tests for acr connected-registry update but we do. Can you please take a look?

Comment thread src/azure-cli/azure/cli/command_modules/acr/connected_registry.py Outdated
Comment thread src/azure-cli/azure/cli/command_modules/acr/connected_registry.py Outdated
Comment thread src/azure-cli/azure/cli/command_modules/acr/connected_registry.py Outdated
@rosanch

Copy link
Copy Markdown
Contributor Author

Xing Zhou (@zhoxing-ms) any updates regarding the testing issue??
cc: Yu Chen (@jsntcy) Julie Zhu (@yanzhudd)

@zhoxing-ms

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Please resolve these CI issues. Please note that we are launching the release for this sprint this week. Please resolve all comments by tomorrow, otherwise the release of this PR will have to be postponed to the next sprint (on 05-21)

@rosanch

Copy link
Copy Markdown
Contributor Author

Xing Zhou (@zhoxing-ms) The issue states that we do not have a az connected-registry update test. However, we do. I believe the testing must be confused because we changed the command from using the custom_command to the generic_update_command to follow CLI best practices. However, the PR testing is saying we do not have any tests in place for the command.

@zhoxing-ms Xing Zhou (zhoxing-ms) changed the title {ACR} connected-registry: commands update. [ACR] connected-registry: commands update. Apr 23, 2024
@zhoxing-ms Xing Zhou (zhoxing-ms) changed the title [ACR] connected-registry: commands update. [ACR] BREAKING CHANGE: connected-registry: commands update Apr 23, 2024
@zhoxing-ms

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Huangli Wu (@huanwu) Actually, I saw other errors in the CI pipeline pipeline link . Please resolve these CI errors first
image

@zhoxing-ms

Xing Zhou (zhoxing-ms) commented Apr 23, 2024 •

Copy link
Copy Markdown
Contributor

[ACR] BREAKING CHANGE: az acr connected-registry install: Group and sub-commands removed
[ACR] BREAKING CHANGE: az acr connected-registry create: Mode default value change from ReadWrite to ReadOnly

Additionally, as this PR includes some breaking changes, it can usually only be released in our breaking change window (Ignite or Build Sprint). Therefore, I suggest postponing its release to the next sprint as the next sprint is a breaking change window for Build (05-21)

@huanwu

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Huangli Wu (@huanwu) Actually, I saw other errors in the CI pipeline pipeline link . Please resolve these CI errors first image

Xing Zhou (@zhoxing-ms), the failure seems unrelated to the change. Can we rerun the tests?

@zhoxing-ms

Xing Zhou (zhoxing-ms) commented Apr 23, 2024 •

Copy link
Copy Markdown
Contributor

Huangli Wu (@huanwu) Rodrigo Mendoza (@rosanch) The reason for these CI issues is that the current yaml file has one less GET request than the code logic, which may be due to a code logic change without re-recording the yaml file. Could you help re-record these failed tests test_acr_connectedregistry in live mode?

@zhoxing-ms

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Huangli Wu (@huanwu) By the way, please add some new test cases for this PR change

Comment on lines -572 to -576
with self.argument_context('acr connected-registry repo') as c:
c.argument('add_repos', options_list=['--add'], nargs='*',
help='repository permissions to be added to the targeted connected registry and it\'s ancestors sync scope maps. Use the format "--add [REPO1 REPO2 ...]" per flag. ' + repo_valid_actions)
c.argument('remove_repos', options_list=['--remove'], nargs='*',
help='repository permissions to be removed from the targeted connected registry and it\'s succesors sync scope maps. Use the format "--remove [REPO1 REPO2 ...]" per flag. ' + repo_valid_actions)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add deprecate_info first to deprecate them, and then remove them in the breaking change window of next sprint

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The entire command was already removed.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What I mean is that these commands are more recommended to be removed in the breaking change window of the next sprint, otherwise it may cause unexpected damage to the customers' automation scripts. You can read this guideline breaking_changes to learn more about CLI breaking change process

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you I'll remove them. I wasn't aware of this new policy. I thought it'd be fine for this command since they were only available for the month of releasee of the feature 2 years ago.

Comment on lines +14 to +16
acr connected-registry update:
rule_exclusions:
- missing_command_test_coverage

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add some test cases for this command instead of excluding it in tests

@rosanch Rodrigo Mendoza (rosanch) Apr 23, 2024 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I already did. That's what I've been asking about for a weeks now. The testing is not reacting to it.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check the test file. The update test has been there for years now...

@zhoxing-ms

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Could you please resolve this conflict file?

@zhoxing-ms

Copy link
Copy Markdown
Contributor

Please note that we are launching the release for this sprint this week. Please resolve all comments by tomorrow, otherwise the release of this PR will have to be postponed to the next sprint (on 07-02)

@yanzhudd

Copy link
Copy Markdown
Contributor

please resolve CI issues

@zhoxing-ms

Xing Zhou (zhoxing-ms) commented Jul 1, 2024 •

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Please resolve these conflicts and CI issues

@zhoxing-ms

Copy link
Copy Markdown
Contributor

#28682 (comment) Please address this comment

@zhoxing-ms

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Since we haven't received a response to this PR for a long time, I will put it in the backlog first. After you have resolved its comments and conflicts, we will consider adding it to the release milestone

@toddysm

Copy link
Copy Markdown
Member

Rodrigo Mendoza (@rosanch) Gavin King (@getk12) Is this still needed

@teresaritorto

Copy link
Copy Markdown
Contributor

Rodrigo Mendoza (@rosanch) Gavin King (@getk12) – Moving this back to Draft for now since this PR has been stale for quite some time and hasn’t seen any recent updates.

@teresaritorto
Teresa Ritorto (teresaritorto) marked this pull request as draft June 2, 2026 16:25

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.