How to judge whether the process ends normally

How to judge whether the process ends normally

You can CreateProcessInstanceWithResult and await the result of the process.

Otherwise, this is a business domain question. What does success mean in your business domain? Do you want to report to a user that the process completed? If you are not awaiting the outcome, then put a service task in there to report out.

Otherwise, the model is management by exception. Processes that fail for technical reasons raise an incident.

Otherwise a process is either inflight or completed. If you need to know about completed instances, you can do one of the following:

  1. CreateProcessInstanceWithResult
  2. Add a service task to the process at the end to report completion
  3. Listen with an exporter
  4. Read ElasticSearch

Only 1 and 2 work on SaaS Camunda Cloud. You can do 1-4 with Self-Hosted.

Aside from that, this is a question about the commercial domain. In your line of employment, what does success entail? Do you want to let a user know when the process is finished? If you aren’t waiting for the outcome, add a service job to report out.

Aside from that, the concept is built around exception handling. An incident occurs when processes fail owing to technical issues.

Hey @Robert_Elite ,

I am not sure about your question about the line of employment. Could you provide a little bit more context?

There are ways to let users know when a process has finished. One way would be indeed to have a service worker that could send out the result as a last step in the process. But I am not sure if you mean that.

Exception handling is something that can be implemented with Cloud as well. There are different ways too. But in general using a process engine in general helps you with a centralized error handling.

I hope that answers some of your points
Cheers
Nele

“Line of employment” sounds like a machine translation that meant to hit “business domain” or “line of business”. So the question is “what does success mean in the business domain?