Count "active" messages

I have a log source that sends an event when an alert is triggered event.type: "Alert Started". Another event is triggered when the alert clears event.type: "Alert Ended"

I'm looking to know how best I can retrieve a count of "active" alerts. i.e. number of alerts that has yet to receive an Alert Ended event.

Any ideas?


You might be able to send the "Alert Started" events straight through, then use an aggregate filter to match up the start and end events. If you set the document_id (I am assuming you are writing to elasticsearch) you can overwrite the document once it has ended. Then in elasticsearch you can query the number of alerts that have not ended.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.