pg-status: microservice for checking the status of PostgreSQL hosts - Mailing list pgsql-announce

From Andrei Krylosov via PostgreSQL Announce
Subject pg-status: microservice for checking the status of PostgreSQL hosts
Date
Msg-id 177001740210.807.12923434630011843879@wrigleys.postgresql.org
Whole thread Raw
List pgsql-announce
 

pg-status: microservice for checking the status of PostgreSQL hosts

Hi all!

I'd like to share a small open‑source project I've been working on: pg-status.

pg-status is a lightweight microservice (sidecar) that helps you instantly determine the status of your PostgreSQL hosts: whether they are alive, which one is the master, which ones are replicas, and how far each replica is lagging behind the master.

It's designed to run alongside your main application. It's lightweight, resource‑efficient, and delivers high performance. You can query it on every request without noticeable overhead.

pg-status polls your database hosts in the background at a configurable interval and exposes an HTTP interface that you can use to retrieve hosts matching given conditions.

I originally built it to speed up master detection in a multi‑host setup where DNS failover was too slow, but it's also handy for proxy setups or custom load‑balancing logic.

More information is available on GitHub: https://github.com/krylosov-aa/pg-status

Feedback and discussion are very welcome. I'd love to hear your thoughts!

Best regards,
Andrei Krylosov

 

pgsql-announce by date:

Previous
From: Pigsty via PostgreSQL Announce
Date:
Subject: PIG v1.0 Released with PGEXT.CLOUD : 444 PG extensions on 14 Linux
Next
From: EDB via PostgreSQL Announce
Date:
Subject: Barman 3.17 Released