sureshanaparti commented on code in PR #13023:
URL: https://github.com/apache/cloudstack/pull/13023#discussion_r3115332312


##########
server/src/main/java/com/cloud/template/HypervisorTemplateAdapter.java:
##########
@@ -338,6 +338,11 @@ protected boolean isZoneAndImageStoreAvailable(DataStore 
imageStore, Long zoneId
             return false;
         }
 
+        if (_imgStoreDao.findById(imageStore.getId()).isReadonly()) {
+            logger.info("Image store [{}] is marked as read-only. Skip 
downloading template to this image store.", imageStore);
+            return false;
+        }

Review Comment:
   use  common method if possible



-- 
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