mirror of https://github.com/apache/cloudstack.git
server: Setting snapshot removed on timeout (#4425)
* Setting snapshot state to error on timeout * Setting removed field so snapshot record is ignored by garbage collection * Removed explicitly setting error status, renamed method from markFailed to markRemoved * Renamed method, moved code a few lines down * Moved remove logic * Removed unused service * Moved removed logic - last time, promise
This commit is contained in:
parent
d3f18ef71c
commit
dfa09fc856
|
|
@ -323,6 +323,7 @@ public class SnapshotServiceImpl implements SnapshotService {
|
|||
if (result.isFailed()) {
|
||||
try {
|
||||
if (createSnapshotPayload.getAsyncBackup()) {
|
||||
_snapshotDao.remove(srcSnapshot.getId());
|
||||
destSnapshot.processEvent(Event.OperationFailed);
|
||||
throw new SnapshotBackupException("Failed in creating backup of snapshot with ID "+srcSnapshot.getId());
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in New Issue