log1 is the start of the process and log2 is the end of the process. How can I get the time taken to complete the process. that is the difference between log2 and log 1.
And also I have log3 , now how do I find the time difference between log3 and log 2
welcome to the Kibana community.
May I ask what is the structure of a document?
Are log1, log2, log3 just different document with a single timestamp or fields of the same document ( i.e. {log1: ..., log2: ..., log3: ... } )?
I've often seen this type of use case where documents store a start and end timestamp value, so using a runtime script can be leveraged to compute a duration field.
I see.
If you need to compute something between two distinct document I think that Transforming data | Elasticsearch Guide [8.4] | Elastic is the best way to achieve that.
Runtime or scripted field are able to operate only at the single document level, while aggregations won't deal with specific documents.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.