DaanHoogland commented on code in PR #6408:
URL: https://github.com/apache/cloudstack/pull/6408#discussion_r890856967


##########
engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/VolumeOrchestrator.java:
##########
@@ -1153,13 +1192,13 @@ public void 
doInTransactionWithoutResult(TransactionStatus status) {
 
         AsyncCallFuture<VolumeApiResult> future = null;
         for (VolumeVO expunge : toBeExpunged) {
+            String expungeToString = getReflectOnlySelectedFields(expunge);
+
             future = 
volService.expungeVolumeAsync(volFactory.getVolume(expunge.getId()));
             try {
                 future.get();
-            } catch (InterruptedException e) {
-                s_logger.debug("failed expunge volume" + expunge.getId(), e);
-            } catch (ExecutionException e) {
-                s_logger.debug("failed expunge volume" + expunge.getId(), e);
+            } catch (InterruptedException | ExecutionException e) {
+                s_logger.error(String.format("Failed to expunge volume [%s] 
due to [%s].", expungeToString, e.getMessage()), e);

Review Comment:
   please don“t log error with exception. If need be add a debug that logs the 
stacktrace



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