harikrishna-patnala commented on a change in pull request #5721:
URL: https://github.com/apache/cloudstack/pull/5721#discussion_r758953514



##########
File path: 
engine/orchestration/src/main/java/com/cloud/vm/VirtualMachineManagerImpl.java
##########
@@ -3808,7 +3808,7 @@ public boolean upgradeVmDb(final long vmId, final 
ServiceOffering newServiceOffe
         if (currentServiceOffering.isDynamic() && 
!newServiceOffering.isDynamic()) {
             removeCustomOfferingDetails(vmId);
         }
-        VMTemplateVO template = 
_templateDao.findById(vmForUpdate.getTemplateId());
+        VMTemplateVO template = 
_templateDao.findByIdIncludingRemoved(vmForUpdate.getTemplateId());

Review comment:
       @sureshanaparti, as @shwstppr mentioned we use deleted template 
properties in other places also. So this procedure looks good to me and we 
cannot consider true because it can happen that the deleted template was not 
dynamically scalable. So better use the template properties as it is




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to