Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Drain per-host reservation when a VM starts on a different host #13363
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
base: main
Are you sure you want to change the base?
Drain per-host reservation when a VM starts on a different host #13363
Changes from all commits
6f0973098ec46c0aef8c865ddaf7cce9cd4File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Uh oh!
There was an error while loading. Please reload this page.
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe this comment is valid and needs attention. reservedCapacity on a host is only ever populated when a VM is stopped there. A running VM's footprint is never moved into that bucket. So the release should be gated on oldState == State.Stopped rather than on newState: that still covers Stopped -> Starting (restart) and Stopped -> Migrating (storage migration
of a stopped VM), both of which genuinely have reserved capacity to release on lastHost, while skipping it for live migration (Running -> Migrating) and AgentReportMigrated, where the source host's footprint is in used, not reserved;releasing there was decrementing unrelated reserved capacity that happened to exist on that host, since it was never this VM's to begin with.
Uh oh!
There was an error while loading. Please reload this page.