cancel
Showing results for 
Search instead for 
Did you mean: 

Statistics about Activiti

lnavet
Champ in-the-making
Champ in-the-making

Hello everyone,

I am currently learning the Activiti tool as part of a JAVA project, so I have:
- Initialized a Maven project by adding the activiti dependencies in my POM (version 5.22.0)
- realized a Workflow (bpmn file)
- used the RuntimeService and TaskService services


=> Everything works perfectly.

However, I want to get statistics on Activiti such as the number of processes in progress, the number of processes in the X state or in the Y state, the processes assigned to X or Y, the number of processes completed that day, yesterday....

Do you know if Activiti offers this type of reporting natively? If so, do you know how I can integrate this module into my project?

I thank you in advance.

Regards,
Lawrence.

2 REPLIES 2

vasile_dirla
Star Contributor
Star Contributor

Have a look here: Activiti User Guide  this could help you. (chapter: 15.8 History)

gdharley
Elite Collaborator
Elite Collaborator

Hello Lawrence,

As Vasile alludes to, Activiti automatically captures a great deal of information about process executions automatically.
All major instance events such as instance start, end, task start, assign, end, variable updates are all captured in the Activiti history tables automatically. 
Activiti provides a Java or Rest API to query these tables for reporting purposes.
Additionally, and to me more importantly, Activiti has recently introduced a powerful Event framework that allows you to capture any number of events and save them into a repository of your choice (such as Elasticsearch). This framework is documented in the Users guide here: Activiti User Guide - Event Handlers 

We have been able to use this event interface to create external depositories of process data for reporting purposes. In my opinion, this is preferable to using the history tables for reporting as reporting load will not impact runtime performance.

Cheers,

Greg