package com.hotwj.platform.system.maintenance.domain.vo;

import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * 媒体资源元数据修复任务状态
 */
@Data
public class MediaResourceMetadataRepairTaskStatusVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    private String taskId;

    private String status;

    private Integer total = 0;

    private Integer processedCount = 0;

    private Integer successCount = 0;

    private Integer skipCount = 0;

    private Integer failCount = 0;

    private Long startTime;

    private Long endTime;

    private Long durationMillis;

    private String operatorName;

    private String requestSummary;

    private String message;

    private List<Long> updatedIds = new ArrayList<>();

    private List<ErrorSample> errorSamples = new ArrayList<>();

    @Data
    public static class ErrorSample implements Serializable {

        @Serial
        private static final long serialVersionUID = 1L;

        private Long resourceId;

        private String fileUrl;

        private String resolvedUrl;

        private String reason;
    }
}
