I’m exploring Zeebe and like product ambition. In my prototype I’ve tried to setup a Kibana dashboard to display mean time to resolve metric for a workflow. So far I’ve been unsuccessful and am looking for recommended approach.
Attempt 1: creating a elastic search query that uses timestamp to calculate MTTRx (Rx=resolve)
I was successful creating the query by painless scripting that summarises timestamp deltas over the elastic documents. In console view I can get MTTRx from scripted query. The code is not very readable and therefor prone to errors. However none of this matters since Kibana doesn’t support displaying cross-document queries so there is no way for me to create a MTTRx dashboard this way.
Attempt 2: Calcuate MTTRx myself and create dashboard based on workflow instance payload
I built a micro services that adds a timestamp as a first and last process step and store the timestamps in the payload. I also calculate a TTRx variable which is the diff between the end and start timestamps. So far so good. I Kibana I run into two problems: 1) the metadata.valueType == VARIABLE is created for the TTRx payload variable however it has no info on which workflow it belongs to. So I would only be able to calculate MTTRx overall all my workflows as one bucket which holds little to no value. 2) the value.value field is of type “text” and not “keyword” which implies that is not “aggregatable” which means I can’t create a scripted field to convert to integer or time or even create a dashboard based on it.
Attempt 3: No idea, all suggestions are welcome