refactor: queue separate jobs for deleting integrity reports

This commit is contained in:
izzy
2025-12-18 17:08:45 +00:00
parent 8b1e29998e
commit 2962c54ee2
5 changed files with 65 additions and 39 deletions

View File

@@ -286,10 +286,19 @@ export interface IIntegrityJob {
refreshOnly?: boolean;
}
export interface IIntegrityDeleteReportJob {
export interface IIntegrityDeleteReportTypeJob {
type?: IntegrityReportType;
}
export interface IIntegrityDeleteReportsJob {
reports: {
id: string;
assetId: string | null;
fileAssetId: string | null;
path: string;
}[];
}
export interface IIntegrityOrphanedFilesJob {
type: 'asset' | 'asset_file';
paths: string[];
@@ -432,7 +441,8 @@ export type JobItem =
| { name: JobName.IntegrityMissingFilesRefresh; data: IIntegrityPathWithReportJob }
| { name: JobName.IntegrityChecksumFiles; data?: IIntegrityJob }
| { name: JobName.IntegrityChecksumFilesRefresh; data?: IIntegrityPathWithChecksumJob }
| { name: JobName.IntegrityReportDelete; data: IIntegrityDeleteReportJob };
| { name: JobName.IntegrityDeleteReportType; data: IIntegrityDeleteReportTypeJob }
| { name: JobName.IntegrityDeleteReports; data: IIntegrityDeleteReportsJob };
export type VectorExtension = (typeof VECTOR_EXTENSIONS)[number];