MCPcopy Index your code
hub / github.com/riverqueue/river / customizableWorkUnit

Struct customizableWorkUnit

internal/jobexecutor/job_executor_test.go:34–39  ·  view source on GitHub ↗

customizableWorkUnit is a wrapper around a workUnit that allows for customization of the workUnit. Unlike in other packages, this one does not make use of any types from the top level river package (like `river.Job[T]`).

Source from the content-addressed store, hash-verified

32// of the workUnit. Unlike in other packages, this one does not make use of any
33// types from the top level river package (like `river.Job[T]`).
34type customizableWorkUnit struct {
35 middleware []rivertype.WorkerMiddleware
36 nextRetry func() time.Time
37 timeout time.Duration
38 work func() error
39}
40
41func (w *customizableWorkUnit) HookLookup(lookup *hooklookup.JobHookLookup) hooklookup.HookLookupInterface {
42 return hooklookup.NewHookLookup(nil)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected