mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-7966:
remove snapshot_store_ref entry, in which role is Primary, during storage GC
This commit is contained in:
parent
73087bc3ff
commit
4e5b3d028d
|
|
@ -1176,6 +1176,10 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C
|
|||
}
|
||||
|
||||
_snapshotDao.remove(destroyedSnapshotStoreVO.getSnapshotId());
|
||||
SnapshotDataStoreVO snapshotOnPrimary = _snapshotStoreDao.findBySnapshot(destroyedSnapshotStoreVO.getSnapshotId(), DataStoreRole.Primary);
|
||||
if (snapshotOnPrimary != null) {
|
||||
_snapshotStoreDao.remove(snapshotOnPrimary.getId());
|
||||
}
|
||||
_snapshotStoreDao.remove(destroyedSnapshotStoreVO.getId());
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue