Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

az cdn custom-domain enable-https call is not idempotent #14500

Closed
jonsing opened this issue Jul 23, 2020 · 7 comments
Closed

az cdn custom-domain enable-https call is not idempotent #14500

jonsing opened this issue Jul 23, 2020 · 7 comments
Assignees
Labels
customer-reported Issues that are reported by GitHub users external to the Azure organization. Network - CDN az cdn Service Attention This issue is responsible by Azure service team.

Comments

@jonsing
Copy link

jonsing commented Jul 23, 2020

In our deployment script for our CDN I noticed that executing az cdn custom-domain enable-https will actually re-provision a new certificate and deploy it even though one is already provisioned and deployed.

No big issue for us because I can not see any impact on the existing certificate and the site continues to work normally during the re-provisioning. But it feels unnecessary and I thought all Azure CLI calls where idempotent 😀

We added a check in our script by listing the custom-domains and checking customHttpsProvisioningState and customHttpsProvisioningSubstate which eliminated the re-provisioning every time we ran our bash script.


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

@ghost ghost added the needs-triage This is a new issue that needs to be triaged to the appropriate team. label Jul 23, 2020
@triage-new-issues triage-new-issues bot added triage and removed triage labels Jul 23, 2020
@ghost ghost added question The issue doesn't require a change to the product in order to be resolved. Most issues start as that and removed needs-triage This is a new issue that needs to be triaged to the appropriate team. labels Jul 23, 2020
@yonzhan yonzhan added Network - CDN az cdn Service Attention This issue is responsible by Azure service team. and removed question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Jul 23, 2020
@ghost
Copy link

ghost commented Jul 23, 2020

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @aznetsuppgithub, @1VarunCh1, @lsmith130.

@yonzhan
Copy link
Collaborator

yonzhan commented Jul 23, 2020

cdn

@fore5fire
Copy link
Contributor

Unfortunately the CDN service uses a POST for this request and is inherently non-idempotent. We do have plans to fix this in the future, but in the mean time we can add a check to see if the parameters are identical in the CLI command before making the update.

@azure-sdk azure-sdk added the customer-reported Issues that are reported by GitHub users external to the Azure organization. label Sep 24, 2020
@navba-MSFT
Copy link
Contributor

@jonsing Apologies for the delayed response. We are looking into this issue and will provide an update once we have more details on the fix.

@lsmith130 Could you please let us know if this issue has been fixed ? Awaiting your reply.

@navba-MSFT
Copy link
Contributor

@t-bzhan Please update this github thread once you get a chance.

@t-bzhan
Copy link
Contributor

t-bzhan commented Feb 7, 2022

Ack, looking into that.

@t-bzhan
Copy link
Contributor

t-bzhan commented Feb 8, 2022

As explained earlier in the issue, "az cdn custom-domain enable-https" underlyingly used POST method which is non-idempotent. Adding a check in CLI could not address the issue completely. There stands a chance that the configuration has been changed after the check, it is better solved in service side but that requires much efforts then.

By the way, It seems that idempotency for CLI commands has been discussed a lot and currently no conclusion has been reached regarding to whether a command should be idempotent or not:
#7613
#12786

I will close the issue for now and will stay tuned to CLI team's suggestion for that. If there are more customers asking for that, we might consider to add the implementation.

@t-bzhan t-bzhan closed this as completed Feb 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
customer-reported Issues that are reported by GitHub users external to the Azure organization. Network - CDN az cdn Service Attention This issue is responsible by Azure service team.
Projects
None yet
Development

No branches or pull requests

6 participants