mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-12-19 23:16:02 +01:00
479d4b4b87
When we right click migrate a VM we load all the hosts in the pool into a dropdown, and then one-by-one assert whether the selected VM can boot on that host, enabling each option where this is positive. If the dropdown is exited then nothing stops these assert calls from continuing, and looking at the logs we can see that they do. With a large pool this is problematic because the UI basically locks up until it's completed all these asserts, even if we've already selected a host to migrate to. If we try to migrate another host then we see in the logs that both the old thread and new thread are making `assert_can_boot_here` calls, and the UI for the new thread doesn't function until the old one has finished. This commit adds a new property `_isDropDownClosed`, which is set by the new `OnDropDownClosed` event handler. In the loop enabling dropdown items, each iteration we check this property - and if it is true then the dropdown is no longer showing so we stop the loop and thus don't call any more `assert_can_boot_here` commands. This stops the UI locking up after the dropdown is closed. Signed-off-by: Callum McIntyre <callum.mcintyre@citrix.com> |
||
---|---|---|
.. | ||
AddHostToSelectedPoolToolStripMenuItem.cs | ||
AddSelectedHostToPoolToolStripMenuItem.cs | ||
AssignVMGroupToolStripMenuItem.cs | ||
CommandButton.cs | ||
CommandConverter.cs | ||
CommandEditor.cs | ||
CommandEditorControl.cs | ||
CommandEditorControl.Designer.cs | ||
CommandEditorControl.ja.resx | ||
CommandEditorControl.resx | ||
CommandEditorControl.zh-CN.resx | ||
CommandToolStripButton.cs | ||
CommandToolStripMenuItem.cs | ||
ContextMenuBuilder.cs | ||
ContextMenuItemCollection.cs | ||
EditPropertiesToolStripMenuItem.cs | ||
MigrateVMToolStripMenuItem.cs | ||
MultipleWarningDialog.cs | ||
MultipleWarningDialog.Designer.cs | ||
MultipleWarningDialog.ja.resx | ||
MultipleWarningDialog.resx | ||
MultipleWarningDialog.zh-CN.resx | ||
ResumeVMOnHostToolStripMenuItem.cs | ||
StartVMOnHostToolStripMenuItem.cs | ||
VMLifeCycleToolStripMenuItem.cs | ||
VMOperationToolStripMenuItem.cs | ||
VMOperationToolStripMenuSubItem.cs | ||
WlbRecommendations.cs |