diff --git a/src/backend/job-backup/service-job-backup/src/main/java/com/tencent/bk/job/backup/archive/AbstractArchivist.java b/src/backend/job-backup/service-job-backup/src/main/java/com/tencent/bk/job/backup/archive/AbstractArchivist.java index ed27664b94..4874b13682 100644 --- a/src/backend/job-backup/service-job-backup/src/main/java/com/tencent/bk/job/backup/archive/AbstractArchivist.java +++ b/src/backend/job-backup/service-job-backup/src/main/java/com/tencent/bk/job/backup/archive/AbstractArchivist.java @@ -279,8 +279,9 @@ private void backupAndDelete() throws IOException { } protected boolean isBackupEnable(ArchiveDBProperties archiveDBProperties) { + ArchiveModeEnum archiveMode = ArchiveModeEnum.valOf(archiveDBProperties.getMode()); return archiveDBProperties.isEnabled() - && ArchiveModeEnum.BACKUP_THEN_DELETE == ArchiveModeEnum.valOf(archiveDBProperties.getMode()); + && (ArchiveModeEnum.BACKUP_THEN_DELETE == archiveMode || ArchiveModeEnum.BACKUP_ONLY == archiveMode); } protected boolean isDeleteEnable(ArchiveDBProperties archiveDBProperties) {