Skip to content

[BUG] VirtualMachineResource UpdateAsync with WaitUntil.Completed is not waiting on long running operation to complete #49172

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

Open
a-santamaria opened this issue Apr 1, 2025 · 3 comments
Assignees
Labels
Compute - VMSS customer-reported Issues that are reported by GitHub users external to the Azure organization. Mgmt This issue is related to a management-plane library. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that

Comments

@a-santamaria
Copy link
Member

Library name and version

Azure.ResourceManager.Compute 1.6.0.0

Describe the bug

Calling UpdateAsync with WaitUntil.Completed is not waiting on long running operation to complete. We see that the operation returns right away

Expected behavior

method call should only return after the vmss LRO has finished.

Actual behavior

method return right away as soon as the operation is accepted but doesn't wait for the LOR to finish

Reproduction Steps

call UpdateAsync with WaitUntil.Completed. We've seen it in scale operations.

you can see our implementation here: https://msazure.visualstudio.com/One/_git/winfab-RP?path=/src/sfmc/SfmcBackendService/Common/AzureClient/SfmcArmClient.cs&version=GBdevelop&_a=contents

            ```

ArmOperation lro = await virtualMachineScaleSet.UpdateAsync(WaitUntil.Completed, vmssUpdate, cancellationToken);
return lro.Value;


### Environment

_No response_
@jsquire
Copy link
Member

jsquire commented Apr 1, 2025

@a-santamaria: Please do not assign labels when opening issues in this repository unless assigning it to yourself or team. It interferes with our automation and breaks triage.

@jsquire jsquire added Mgmt This issue is related to a management-plane library. customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team labels Apr 1, 2025
@ArthurMa1978
Copy link
Member

Same issue as #48740

@ArthurMa1978
Copy link
Member

This is a known issue on the service side, the reason is:
The VMSS PATCH LRO returns 200 instead of arm regulation 202.
The response header contains Azure-AsyncOperation which seems like the service want us to poll next link.
But our .NET SDK will ignore the header if the method is patch and status code is 200 at this method. And call the final GET resource operation, end the LRO instantly.
And also, at this point, even with the portal shows the patch still in progress, the get operation returned "provisioningState": "Succeeded".

Here is an issue created to track this on service side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compute - VMSS customer-reported Issues that are reported by GitHub users external to the Azure organization. Mgmt This issue is related to a management-plane library. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Projects
None yet
Development

No branches or pull requests

3 participants