make virtual machine reconcile async#1697
Conversation
|
Tests, lint are still todo. |
ba7876c to
49a86d5
Compare
d8ed261 to
3ce3007
Compare
|
Removing [WIP] as this is ready for review but going to add a hold so it doesn't merge until after the release since it's a massive change /hold |
|
I know this seems like a lot of changes but... here are the main things going on:
And FWIW, this PR overall removes code while maintaining test coverage: before: https://prow.k8s.io/view/gs/kubernetes-jenkins/logs/periodic-cluster-api-provider-azure-coverage/1442449517906497536 |
|
|
||
| osProfile, err := s.generateOSProfile(ctx, vmSpec) | ||
| // Discover addresses for NICs associated with the VM | ||
| addresses, err := s.getAddresses(ctx, vm, vmSpec.ResourceGroupName()) |
There was a problem hiding this comment.
future work I'm considering: figure out how to do this without needing to get the NICs and IPs again (we created them earlier), but this would be another refactor so holding off for now since this PR already does a lot. Kept that function as-is.
|
/retest |
3ce3007 to
c0fc969
Compare
|
@CecileRobertMichon: GitHub didn't allow me to request PR reviews from the following users: karuppiah7890. Note that only kubernetes-sigs members and repo collaborators can review this PR, and authors cannot review their own PRs. DetailsIn response to this: Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
cf6740a to
930c3ca
Compare
| return err | ||
| return nil, nil, errors.Wrapf(err, "failed to get desired parameters for virtual machine %s", spec.ResourceName()) | ||
| } else if vm == nil { | ||
| // nothing to do here. |
There was a problem hiding this comment.
self-review: maybe this should return the result as the existing vm instead of returning nil so we can act upon the existing VM even if it already exists
There was a problem hiding this comment.
Could be added in the future if needed.
shysank
left a comment
There was a problem hiding this comment.
/lgtm overall with one small clarification
|
went through it again now and lgtm |
|
/approve |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: nader-ziada The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
/test pull-cluster-api-provider-azure-e2e |
|
@CecileRobertMichon: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
|
/test pull-cluster-api-provider-azure-e2e |

What type of PR is this?
/kind feature
What this PR does / why we need it: implements #1541 for virtual machines.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)format, will close the issue(s) when PR gets merged):Fixes #
Special notes for your reviewer:
Please confirm that if this PR changes any image versions, then that's the sole change this PR makes.
TODOs:
Release note: