Exemple #1
0
func MarkTaskUndispatched(t *task.Task) error {
	// record that the task as undispatched on the host
	if err := t.MarkAsUndispatched(); err != nil {
		return err
	}
	// the task was successfully dispatched, log the event
	event.LogTaskUndispatched(t.Id, t.Id)

	// update the cached version of the task in its related build document
	if err := build.SetCachedTaskUndispatched(t.BuildId, t.Id); err != nil {
		return err
	}
	return nil
}