mirror of
https://github.com/goharbor/harbor
synced 2025-04-22 18:31:41 +00:00
Update job status when failed to submit it
Set the status of replication job to "error" when the submitting to jobservice fails
This commit is contained in:
parent
d557ec89d7
commit
4ecbf3c0f5
@ -119,6 +119,9 @@ func (d *DefaultReplicator) Replicate(replication *Replication) error {
|
|||||||
|
|
||||||
uuid, err := d.client.SubmitJob(job)
|
uuid, err := d.client.SubmitJob(job)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
if er := dao.UpdateRepJobStatus(id, common_models.JobError); er != nil {
|
||||||
|
log.Errorf("failed to update the status of job %d: %s", id, er)
|
||||||
|
}
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user