Skip to content

Commit d63a816

Browse files
weizhouapachedhslove
authored andcommitted
server: fix scale vm with same disk offering id (apache#10235)
1 parent ac46cef commit d63a816

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

server/src/main/java/com/cloud/vm/UserVmManagerImpl.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2189,7 +2189,7 @@ protected void validateDiskOfferingChecks(ServiceOfferingVO currentServiceOfferi
21892189
throw new InvalidParameterValueException("Unable to Scale VM, since disk offering strictness flag is not same for new service offering and old service offering");
21902190
}
21912191

2192-
if (currentServiceOffering.getDiskOfferingStrictness() && currentServiceOffering.getDiskOfferingId() != newServiceOffering.getDiskOfferingId()) {
2192+
if (currentServiceOffering.getDiskOfferingStrictness() && !currentServiceOffering.getDiskOfferingId().equals(newServiceOffering.getDiskOfferingId())) {
21932193
throw new InvalidParameterValueException("Unable to Scale VM, since disk offering id associated with the old service offering is not same for new service offering");
21942194
}
21952195

0 commit comments

Comments
 (0)