Suspend, Activate and Delete an Execution

319 views
Skip to first unread message

clint....@gmail.com

unread,
Jul 11, 2013, 11:30:29 AM7/11/13
to camunda-...@googlegroups.com
Hi,
Recently, we got a set of requirements asking to implement the ability to Suspend, Activate and Delete an Execution in the Camunda Rest API. After some investigation, I noticed the Camunda Engine has very similar functionality associated with a Process Instance, but not a child execution. I wanted to ask the community's opinion on whether it is a good idea to expose this functionality? If not then why not? Also, would the community want such capability in the API? Thoughts?

Regards, Clint

thorben....@camunda.com

unread,
Jul 11, 2013, 12:03:50 PM7/11/13
to camunda-...@googlegroups.com, clint....@gmail.com
Hi Clint,

I'd like to know more about your use case. I could imagine that this feature is useful, if you want to safely correct a single execution path (e.g. changing runtime variables) of a complex process instance and do not want to interrupt it completely.

From a technical perspective: In general the functionality is quite similar, that's right. If you expect suspending an execution to also suspend all children, then it becomes a little more complicated: For process instances, we can easily update all child executions with a single SQL statement, because they have a direct reference to the process instance. For single executions, we need some kind of recursion, which would have to be implemented in Java I assume, so all children of the execution have to be fetched, their children again and so on. Should not be too complicated though.

Best regards,
Thorben

clint....@gmail.com

unread,
Jul 12, 2013, 5:31:17 AM7/12/13
to camunda-...@googlegroups.com, clint....@gmail.com
The example scenario given by the client was similar to what you mentioned. They want to act on an execution path while not interrupting the entire process instance.

thorben....@camunda.com

unread,
Jul 19, 2013, 9:34:31 AM7/19/13
to camunda-...@googlegroups.com, clint....@gmail.com
Hi Clint,

I agree with you that this is a useful feature. For the time being, we cannot build it ourselves, but if you would like to contribute, go right ahead.
What is your expected behavior with respect to child executions and especially call activities, i.e. if there is a process instance that has been "called" by the execution you want to suspend? For process instances, we decided to not touch other instances created by call activities of the current process instance, so it would be favourable to keep this behavior consistent, when we add this functionality.

Best regards,
Thorben

clint....@gmail.com

unread,
Jul 22, 2013, 8:20:35 AM7/22/13
to camunda-...@googlegroups.com, clint....@gmail.com
Hi,

"What is your expected behavior with respect to child executions"

Child executions would be suspended/activated along with the parent.

"For process instances, we decided to not touch other instances created by call activities of the current process instance, so it would be favorable to keep this behavior consistent, when we add this functionality."
There is no requirement to alter this current behavior, so it would stay the same.

At the moment, this feature has been put on hold (possibly removed). There is some concern regarding the dangers of working on executions, particularly canceling/deleting an execution. This change would also impact how jobs that are eligible for execution are retrieved from a DB. I, hopefully, will revisit the issue in August. Thank you!


Regards, Clint

Reply all
Reply to author
Forward
0 new messages