JoaoJandre commented on code in PR #9390:
URL: https://github.com/apache/cloudstack/pull/9390#discussion_r1683387206


##########
plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java:
##########
@@ -766,26 +766,53 @@ public KVMStoragePool createStoragePool(String name, 
String host, int port, Stri
         }
     }
 
+    private boolean destroyStoragePool(Connect conn, String uuid) throws 
LibvirtException
+    {

Review Comment:
   ```suggestion
       private boolean destroyStoragePool(Connect conn, String uuid) throws 
LibvirtException {
   ```



##########
plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/storage/LibvirtStorageAdaptor.java:
##########
@@ -766,26 +766,53 @@ public KVMStoragePool createStoragePool(String name, 
String host, int port, Stri
         }
     }
 
+    private boolean destroyStoragePool(Connect conn, String uuid) throws 
LibvirtException
+    {
+        StoragePool sp;
+        try {
+            sp = conn.storagePoolLookupByUUIDString(uuid);
+        } catch (LibvirtException exc) {
+            s_logger.warn("Storage pool " + uuid + " doesn't exist in libvirt. 
Assuming it is already removed");

Review Comment:
   This is masking the exception, we should at least log it.



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