Question:
I have a specific use case where tasks in my Camunda BPMN workflow have timer boundary events. When a task is active, its timer boundary event is represented in the ACT_RU_JOB
table. Once the timer triggers or the task completes, the entry is moved to the ACT_HI_JOB
table. The due dates for active timer events can be updated by modifying the DUEDATE_
field in the ACT_RU_JOB
table. If a task is reopened, the timer configuration is taken from the ACT_RU_JOBDEF
table. If the configured due date has already passed, the timer event triggers immediately, completing the task and leaving no opportunity to change the due date in the ACT_RU_JOB
table. Changing the job definition in the ACT_RU_JOBDEF
table affects all instances of that timer, which is generally not recommended unless a global change is intended.
Use Case:
- Tasks in the workflow are sequential and have timer boundary events.
- Each task can either be completed or moved back to a previous task.
- When a task is moved back to a previous task, the due dates of the timer boundary events for all preceding tasks need to be updated to match the due date of the timer boundary event of the task from which it was returned.
Objective:
I need a dynamic solution where:
- When a task is sent back to a previous task, the due dates for the timer boundary events of all preceding tasks are updated to match the timer boundary event of the task from which it is returned.
- This update should occur through a Camunda service that dynamically fetches the details of the previous tasks and updates their due dates accordingly.
Questions:
- Is it possible to implement this scenario dynamically within Camunda?
- What would be the best approach to achieve this? Should I manipulate the
DUEDATE_
field in theACT_RU_JOB
table directly via a custom service? - Are there any best practices or recommendations for handling such dynamic updates to timer boundary events when tasks are moved back in the workflow?
Current Understanding:
- Active timer events can have their due dates updated by changing the
DUEDATE_
field in theACT_RU_JOB
table. - When tasks are reopened, the timer configurations are taken from the
ACT_RU_JOBDEF
table. - Changing the job definition in the
ACT_RU_JOBDEF
table affects all instances, which may not be desirable.
Any insights, examples, or guidance on this would be greatly appreciated.
Thank you!