2
0
mirror of https://github.com/hibiken/asynq.git synced 2026-06-22 20:28:55 +08:00

Add Options() accessor on Task for external option merging

Exposes the opts field so callers can read a task's options to merge
with additional per-task options at batch time.
This commit is contained in:
Erik Nilsen
2026-02-25 09:11:52 -08:00
parent 71ebcfa129
commit 7ae0b3fe22

View File

@@ -40,6 +40,7 @@ type Task struct {
func (t *Task) Type() string { return t.typename }
func (t *Task) Payload() []byte { return t.payload }
func (t *Task) Headers() map[string]string { return t.headers }
func (t *Task) Options() []Option { return t.opts }
// ResultWriter returns a pointer to the ResultWriter associated with the task.
//