simulator supports migration

Add simultor to the seemingly strict filter which should happen within
the hypervisor resource and not the virtualmachine :/

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
(cherry picked from commit 3d4d350dbe9728d3de42e4ee7a6ad06c6e10fced)
This commit is contained in:
Prasanna Santhanam 2013-07-30 11:16:04 +05:30
parent 7bccc3e133
commit 34e751fb8d

View File

@ -3801,7 +3801,8 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Vir
if (!vm.getHypervisorType().equals(HypervisorType.XenServer)
&& !vm.getHypervisorType().equals(HypervisorType.VMware)
&& !vm.getHypervisorType().equals(HypervisorType.KVM)
&& !vm.getHypervisorType().equals(HypervisorType.Ovm)) {
&& !vm.getHypervisorType().equals(HypervisorType.Ovm)
&& !vm.getHypervisorType().equals(HypervisorType.Simulator)) {
if (s_logger.isDebugEnabled()) {
s_logger.debug(vm
+ " is not XenServer/VMware/KVM/Ovm, cannot migrate this VM.");
@ -4116,7 +4117,8 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Vir
if (!vm.getHypervisorType().equals(HypervisorType.XenServer) &&
!vm.getHypervisorType().equals(HypervisorType.VMware) &&
!vm.getHypervisorType().equals(HypervisorType.KVM) &&
!vm.getHypervisorType().equals(HypervisorType.Ovm)) {
!vm.getHypervisorType().equals(HypervisorType.Ovm) &&
!vm.getHypervisorType().equals(HypervisorType.Simulator)) {
throw new InvalidParameterValueException("Unsupported hypervisor type for vm migration, we support" +
" XenServer/VMware/KVM only");
}