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

fix(controller): Optimize logic for detach VG from VM for cases with large number of VGs #477

Merged
merged 5 commits into from
Aug 25, 2024

Conversation

thunderboltsid
Copy link
Contributor

We optimize the logic and add some guardrails

  • Add a timeout on the context for polling
  • Increase the polling interval to 5s
  • Set immediate polling to false to reduce likelihood of a 404 on tasks
  • Call detachVG one after the other and build a list of tasks
  • wait for all tasks in the list to reach a terminal state

@thunderboltsid thunderboltsid requested review from jimmidyson and removed request for adiantum and yannickstruyf3 August 25, 2024 02:04
Copy link

codecov bot commented Aug 25, 2024

Codecov Report

Attention: Patch coverage is 7.14286% with 13 lines in your changes missing coverage. Please review.

Project coverage is 33.00%. Comparing base (5d63d09) to head (69f7b5b).
Report is 1 commits behind head on main.

Files Patch % Lines
controllers/nutanixmachine_controller.go 12.50% 7 Missing ⚠️
controllers/helpers.go 0.00% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #477      +/-   ##
==========================================
+ Coverage   32.56%   33.00%   +0.43%     
==========================================
  Files          17       17              
  Lines        1833     1809      -24     
==========================================
  Hits          597      597              
+ Misses       1216     1192      -24     
  Partials       20       20              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

controllers/helpers.go Outdated Show resolved Hide resolved
@jimmidyson jimmidyson requested a review from faiq August 25, 2024 14:21
@thunderboltsid thunderboltsid merged commit 0883e55 into main Aug 25, 2024
8 of 11 checks passed
@thunderboltsid thunderboltsid deleted the jira/NCN-102041 branch August 25, 2024 15:00
@thunderboltsid thunderboltsid added the bug Something isn't working label Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants