Reporting strategy

What is your strategy for reporting? I want to fetch process data (variables, time, duration, etc.) to load it to a data warehouse for analyzing purposes. I can imagine 2 approaches:

  • I will understand Flowable database model, mirror it and fetch data i.e. once a day. But the data model is quite complex.
  • I will query process instances via REST API i.e. once a day and load it to my warehouse but it could be resource-consuming and affect Flowable stability if huge process volumes are involved.
    Is there any recommended solution?

Another possibilities (not complete list):

  • Something similar as async history, after each event create a job which will keep DWH in sync.
  • custom queries to get only data related to your task.