--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/25f2ae7c-3f8e-4268-a872-9f4ebc2917d2%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to promethe...@googlegroups.com.
My understanding is that this depends on what information you send to
Alertmanager in your alert. If you send an alert with an 'endsAt' and
then do nothing more, Alertmanager will only consider the alert resolved
when it reaches that endsAt time. If you send an alert with no 'endsAt',
Alertmanager sets its endsAt time to now plus your resolve_timeout value
(five minutes by default), and so it will resolve in five minutes from
your notification.
(If you re-send your alert with a different endsAt, or without one,
the new endsAt value (either yours or the computed one) overwrites
the current endsAt. Prometheus normally sends alerts to Alertmanager
with an endsAt a few minutes in the future and then keeps re-sending
them to keep Alertmanager from resolving the alert.)
If you want to mark an alert as explicitly resolved, I believe that you
re-send it with an endsAt date that is now or in the immediate past.
If I'm understanding this correctly, you could implement one-shot
alert notification by sending the initial alert with an endsAt date
well into the future. However this isn't necessarily safe; if the
service is unable to send a notification to Alertmanager when the
alert is resolved, the alert will linger on as active. Constantly
renewing the alert serves as a useful signal that the alert really
still is there.
(Of course this has downsides. If you have a bunch of alerts and then
Prometheus dies and stays down for a few minutes, I believe that
Alertmanager will declare all of those alerts resolved even though they
may not be at all. Then when Prometheus comes back with the alerts still
active and re-sends them to Alertmanager, Alertmanager will consider them
to be new alerts and send out new notices for them. In some situations
latching alerts as on when you lose contact with the source triggering
the alert is a feature.)
- cks
> "Is AM can be indicated for the alert raised by mservice to be hold as
> is, till it (mservice send) clea to alert manager(AM) ?"
>
> No, Alertmanager will consider the alert cleared after
> resolve_timeout (5m, by default) if the alert has not been updated -
> that's part of its basic design.
>
>
> On Wednesday, November 6, 2019 at 1:37:19 PM UTC-5, Nitin Gupta wrote:
> >
> > Thanks benjamin.
> >
> > Limitations through prometheus is data conveyed via metric v/s sending
> > this data directly by mservice.. . to alert manager.
> >
> > Is AM can be indicated for the alert raised by mservice to be hold as is,
> > till it (mservice send) clea to alert manager(AM) ?
> > Is there a way to achieve!!
> >
> > As the mservice doesn't have book-keeping of alert once it's reported
> > out.. . Therefore it can't send same again to AM if it expect to be so..
> >
> >
> >
> >
> > On Wed, 6 Nov 2019, 22:57 Benjamin Ritcey, <b...@ritcey.com <javascript:>>