Have a lot of running activities stored.
The HistoricActivityInstance#selectRunningHistoricActivityPage query is executed.
The query execution is slow.
Improved performance (similar to The HistoricActivityInstance#selectCompletedHistoricActivityPage query).
There is a composite index missing on ACT_HI_ACTINST for START_TIME_ and END_TIME_ .
As the query filters by END_TIME_ and sorts by START_TIME_.
Manual creation of that index on a postgres DB reduced the response time from >20s to <1s.