Steps to reproduce
- there is a lot of entries in historic activity database table
- request Historic activity statistics by calling {{GET /history/process-definition/
{id}
/statistics}}
Actual result
- it takes too long the query to be completed, sometimes the timeout happens
Expected result
- statistics is returned in reasonable amount of time, no matter how large the database is