JoaoJandre commented on code in PR #12949:
URL: https://github.com/apache/cloudstack/pull/12949#discussion_r3041332328
##########
engine/storage/snapshot/src/main/java/org/apache/cloudstack/storage/vmsnapshot/StorageVMSnapshotStrategy.java:
##########
@@ -448,6 +455,7 @@ protected SnapshotInfo createDiskSnapshot(VMSnapshot
vmSnapshot, List<SnapshotIn
vol.addPayload(setPayload(vol, snapshot, quiescevm));
SnapshotInfo snapshotInfo =
snapshotDataFactory.getSnapshot(snapshot.getId(), vol.getDataStore());
snapshotInfo.addPayload(vol.getpayload());
+ volumeToSnapshotInfoMapForRollback.put(vol.getId(), snapshotInfo);
Review Comment:
The else is so we have the updated snapshot info to delete. Although, I'm
not familiar enough with this code to say that it makes a difference. Anyway,
if it does make a difference, I would just remove the else to reduce
indentation; if it does not make a difference, I would only add the info once
on the hashmap.
--
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]