Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
engine: Fix duplicate VM backup entry error when creating incremental…
… backup Fixes an issue that originates from ed023e5 The following error occured when trying to create an incremental backup: ------ ERROR [org.ovirt.engine.core.bll.storage.backup.HybridBackupCommand] (default task-1) [full_cold_vm_backup] Command 'org.ovirt.engine.core.bll.storage.backup.HybridBackupCommand' failed: CallableStatementCallback; SQL [{call insertvmbackup(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)}]; ERROR: duplicate key value violates unique constraint "vm_backups_pkey" Detail: Key (backup_id)=(1733241d-4a0b-4205-9e52-5383eb7a82f2) already exists. ----- This was caused by using vmBackupDao.save() instead of vmBackupDao.update(), because the backup already existed when the setVmBackupSnapshot method is executed. Signed-off-by: Brooklyn Dewolf <[email protected]>
- Loading branch information