mirror of
https://github.com/peridotbuild/peridot.git
synced 2024-10-08 08:54:12 +00:00
If entry ID is not set, delete entry for failed entries
This commit is contained in:
parent
a7332a640b
commit
847abe2258
@ -179,6 +179,12 @@ func ProcessRPMWorkflow(ctx workflow.Context, args *mothershippb.ProcessRPMArgs)
|
||||
MaximumAttempts: 0,
|
||||
},
|
||||
})
|
||||
|
||||
// Check if entry has EntryID set, if not then we can just delete the entry
|
||||
if entry.EntryId == "" {
|
||||
_ = workflow.ExecuteActivity(ctx, w.DeleteEntry, entry.Name).Get(ctx, nil)
|
||||
return
|
||||
}
|
||||
_ = workflow.ExecuteActivity(ctx, w.SetEntryState, entry.Name, mothershippb.Entry_FAILED, nil).Get(ctx, nil)
|
||||
}()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user