cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anshul1886 <>
Subject [GitHub] cloudstack pull request #1867: CLOUDSTACK-9706: Added snapshots cleanup in s...
Date Thu, 16 Mar 2017 10:57:40 GMT
Github user anshul1886 commented on a diff in the pull request:
    --- Diff: server/src/com/cloud/storage/ ---
    @@ -1078,6 +1082,16 @@ public void cleanupStorage(boolean recurring) {
    +                    //destroy snapshots in destroying state in snapshot_store_ref
    +                    List<SnapshotDataStoreVO>  ssSnapshots = _snapshotStoreDao.listByState(ObjectInDataStoreStateMachine.State.Destroying);
    +                    for(SnapshotDataStoreVO ssSnapshotVO : ssSnapshots){
    +                        try {
    +                            _snapshotService.deleteSnapshot(snapshotFactory.getSnapshot(ssSnapshotVO.getSnapshotId(),
    --- End diff --
    @koushik-das If there is any failure in deleteSnapshot() then cleanup will be retried.
DB entry for such snapshots will only be removed on successful deletion. Destroying check
 introduced in SnapshotObject class is to make sure that DB entry doesn't gets deleted.

If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at or file a JIRA ticket
with INFRA.

View raw message