hapostgres / pg_auto_failover

Postgres extension and service for automated failover and high-availability
Other
1.07k stars 113 forks source link

Trigger event on cluster status change #917

Open xinferum opened 1 year ago

xinferum commented 1 year ago

Hello.

Tell me, is it possible to somehow receive information on the monitor that something has changed in the status of the cluster (roles have changed, the TLI of servers has changed, the server has become unavailable / returned to the cluster, etc.)?

I know that it is possible to query pg_autoctl show state cluster status and pg_autoctl show events cluster events, but I would like to be able to somehow automatically know from the monitor that the cluster status has changed and alert about it. what can i link to?

Of course, you can regularly check whether new messages have appeared in events and respond to this, but maybe there is another way?