DaanHoogland commented on code in PR #8031:
URL: https://github.com/apache/cloudstack/pull/8031#discussion_r1351615410
##########
engine/storage/snapshot/src/main/java/org/apache/cloudstack/storage/snapshot/SnapshotServiceImpl.java:
##########
@@ -418,15 +418,13 @@ public boolean deleteSnapshot(SnapshotInfo snapInfo) {
if (result.isFailed()) {
throw new CloudRuntimeException(result.getResult());
}
+ s_logger.debug(String.format("Successfully deleted snapshot [%s]
with ID [%s].", snapInfo.getName(), snapInfo.getUuid()));
return true;
- } catch (InterruptedException e) {
- s_logger.debug("delete snapshot is failed: " + e.toString());
- } catch (ExecutionException e) {
- s_logger.debug("delete snapshot is failed: " + e.toString());
+ } catch (InterruptedException | ExecutionException e) {
+ s_logger.error(String.format("Failed to delete snapshot [%s] due
to: [%s].", snapInfo.getUuid(), e.getMessage()), e);
Review Comment:
```suggestion
s_logger.error(String.format("Failed to delete snapshot [%s] due
to: [%s].", snapInfo.getUuid(), e.getMessage()));
s_logger.error(String.format("Failed to delete snapshot [%s].",
snapInfo.getUuid()), e);
```
--
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]