You've already forked woodpecker
mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2026-06-03 16:35:37 +02:00
Simplify queue interface (#5449)
This commit is contained in:
@@ -77,9 +77,6 @@ type FilterFn func(*model.Task) (bool, int)
|
||||
// Queue defines a task queue for scheduling tasks among
|
||||
// a pool of workers.
|
||||
type Queue interface {
|
||||
// Push pushes a task to the tail of this queue.
|
||||
Push(c context.Context, task *model.Task) error
|
||||
|
||||
// PushAtOnce pushes multiple tasks to the tail of this queue.
|
||||
PushAtOnce(c context.Context, tasks []*model.Task) error
|
||||
|
||||
@@ -98,9 +95,6 @@ type Queue interface {
|
||||
// ErrorAtOnce signals multiple done are complete with an error.
|
||||
ErrorAtOnce(c context.Context, ids []string, err error) error
|
||||
|
||||
// Evict removes a pending task from the queue.
|
||||
Evict(c context.Context, id string) error
|
||||
|
||||
// EvictAtOnce removes multiple pending tasks from the queue.
|
||||
EvictAtOnce(c context.Context, ids []string) error
|
||||
|
||||
|
||||
Reference in New Issue
Block a user