pg_auto_failover
pg_auto_failover copied to clipboard
Improve pg_autoctl shutdown sequence
Both systemd and Kubernetes use a shutdown sequence that sends a SIGTERM signal then later a stronger one. See https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-termination for instance, where the default is to provide pods with a 30s grade period.
At the moment pg_autoctl is not smart about the grace period. It could be made to switch the current node to MAINTENANCE mode and then have a way to automatically re-join the cluster at the next start-up.
Hi,
I am looking into running pg_autctl in a kubernetes container, and this feature would be very handy. Is there any reason why the PR #680 has been abandoned?