Skip to content

Commit 516a953

Browse files
committed
Rename variable
1 parent d91ef4b commit 516a953

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

engine/orchestration/src/main/java/org/apache/cloudstack/engine/orchestration/DataMigrationUtility.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -322,10 +322,10 @@ protected List<DataObject> getAllReadySnapshotsAndChains(DataStore srcDataStore,
322322

323323
if (isKvmIncrementalSnapshot) {
324324
List<SnapshotInfo> kvmIncrementalSnapshotChain = createKvmIncrementalSnapshotChain(snapshot);
325-
SnapshotInfo parent = kvmIncrementalSnapshotChain.get(0);
325+
SnapshotInfo firstSnapshotInTheChain = kvmIncrementalSnapshotChain.get(0);
326326
snapshotIdsAlreadyInChain.addAll(kvmIncrementalSnapshotChain.stream().map(DataObject::getId).collect(Collectors.toSet()));
327-
snapshotChains.put(parent, new Pair<>(kvmIncrementalSnapshotChain, getTotalChainSize(kvmIncrementalSnapshotChain.stream().filter(snapInfo -> snapshotIdsToMigrate.contains(snapInfo.getId())).collect(Collectors.toList()))));
328-
files.add(parent);
327+
snapshotChains.put(firstSnapshotInTheChain, new Pair<>(kvmIncrementalSnapshotChain, getTotalChainSize(kvmIncrementalSnapshotChain.stream().filter(snapInfo -> snapshotIdsToMigrate.contains(snapInfo.getId())).collect(Collectors.toList()))));
328+
files.add(firstSnapshotInTheChain);
329329
} else {
330330
SnapshotInfo snap = snapshotFactory.getSnapshot(snapshotVO.getSnapshotId(), snapshot.getDataStoreId(), snapshot.getRole());
331331
if (snap == null) {

0 commit comments

Comments
 (0)