mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-6833 [Hyper-V] Volume snapshot creation returns success even though snapshots are not supported for Hyper-V
(cherry picked from commit 945e879bf2)
This commit is contained in:
parent
91391e6779
commit
1f7d2ee091
|
|
@ -1662,6 +1662,9 @@ public class VolumeApiServiceImpl extends ManagerBase implements VolumeApiServic
|
|||
if (volume.getInstanceId() != null)
|
||||
vm = _vmInstanceDao.findById(volume.getInstanceId());
|
||||
|
||||
if (volume.getHypervisorType() == HypervisorType.Hyperv) {
|
||||
throw new InvalidParameterValueException("Volume Snapshots are not supported on Hypervisor Type : Hyper-V");
|
||||
}
|
||||
if (vm != null) {
|
||||
// serialize VM operation
|
||||
AsyncJobExecutionContext jobContext = AsyncJobExecutionContext.getCurrentExecutionContext();
|
||||
|
|
|
|||
Loading…
Reference in New Issue