Skip to content

Commit

Permalink
expose ExtendLock in task context
Browse files Browse the repository at this point in the history
  • Loading branch information
manu88 authored and liderman committed Oct 7, 2022
1 parent 4908fb1 commit 55ce926
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions processor/processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,14 @@ func (c *Context) Complete(query QueryComplete) error {
})
}

// Extend the lock for a new duration
func (c *Context) ExtendLock(newDurationMS int) error {
return c.client.ExternalTask.ExtendLock(c.Task.Id, camundaclientgo.QueryExtendLock{
NewDuration: &newDurationMS,
WorkerId: &c.Task.WorkerId,
})
}

// HandleBPMNError handle external task BPMN error
func (c *Context) HandleBPMNError(query QueryHandleBPMNError) error {
return c.client.ExternalTask.HandleBPMNError(c.Task.Id, camundaclientgo.QueryHandleBPMNError{
Expand Down

0 comments on commit 55ce926

Please sign in to comment.