Skip to content

Commit

Permalink
feat: add WithId
Browse files Browse the repository at this point in the history
  • Loading branch information
pcfreak30 committed Jul 9, 2024
1 parent 9747c90 commit 6e1fcc6
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions job.go
Original file line number Diff line number Diff line change
Expand Up @@ -610,6 +610,16 @@ func WithTags(tags ...string) JobOption {
}
}

// WithIdentifier sets the identifier for the job. The identifier
// is used to uniquely identify the job and is used for logging
// and metrics.
func WithIdentifier(id uuid.UUID) JobOption {
return func(j *internalJob) error {
j.id = id
return nil
}
}

// -----------------------------------------------
// -----------------------------------------------
// ------------- Job Event Listeners -------------
Expand Down

0 comments on commit 6e1fcc6

Please sign in to comment.