prometheus / alertmanager

Prometheus Alertmanager
https://prometheus.io
Apache License 2.0
6.64k stars 2.15k forks source link

Eventstream endpoint #1304

Open stuartnelson3 opened 6 years ago

stuartnelson3 commented 6 years ago

Live update endpoint, like a websocket that you can subscribe to that receives updates based on mesh info, incoming alerts, when an alert is silenced. Clients could consume this to e.g. live update the AM UI, or update a Prometheus UI to show an alert is silenced or the last time a notification was sent

miguel250 commented 6 years ago

Hi @stuartnelson3, would it be possible for me to work on adding this feature using websockets?

Thanks

stuartnelson3 commented 6 years ago

I wrote websocket in the original post, but now I'm thinking server sent events might be more appropriate. But yes, you're more than welcome to work on it!

miguel250 commented 6 years ago

Thanks! I will update this ticket with what we have in a few days.

metalmatze commented 6 years ago

After seeing the initial description I wanted to jump in to the discussion to tell you that server sent events are better. But you already did this. We probably don't need events to be send from the client to the server, right?

I'd also like to add, that drone moved from websockets to SSE one year ago. People always had problems, like timeouts, running this behind the proxies. SSE on the other hand are just a normal HTTP request.

stuartnelson3 commented 6 years ago

We probably don't need events to be send from the client to the server, right?

Yeah, my idea was for this to be consumption only.