Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1virta-0005PU-00 for pgsql-general@arkaria.postgresql.org; Thu, 22 Jan 2026 10:26:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1virtX-00CTHX-1R for pgsql-general@arkaria.postgresql.org; Thu, 22 Jan 2026 10:26:31 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1virtX-00CTHM-0A for pgsql-general@lists.postgresql.org; Thu, 22 Jan 2026 10:26:31 +0000 Received: from mail-lj1-x229.google.com ([2a00:1450:4864:20::229]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1virtV-001sux-05 for pgsql-general@lists.postgresql.org; Thu, 22 Jan 2026 10:26:31 +0000 Received: by mail-lj1-x229.google.com with SMTP id 38308e7fff4ca-385bdc72422so8001201fa.1 for ; Thu, 22 Jan 2026 02:26:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1769077587; cv=none; d=google.com; s=arc-20240605; b=V0H+C9JefoCKJPbvtFWtTsinxU1bSHAhLtqunAkBA3ObrAVWHWePipwBk8GG4PZNDz 8GMYU2ulcbcV485pERIrnxLRdt00aarAFFeaUpZPUYex0uiiO5O3l5r60EKha/u78cBq Acy7s6IPZ2Q6o//rGTdBnJxG0wI9/K7Fvr9XZyZzOIPmZn4DS7l5DtxBdqbsTZt9ria1 U6Xs89/Xtzh7bbXuFsh5imO+Iv4hht0L53+JpQh+lYLEhUrwMLzZD8ARqSrDDbQZzB27 Fcsfms6W2YH4mSvAG8kK/Lwp3KMHE55Zh3QkrJ0WGAkSPCSrtVPT4h1DOkMpOq7MfsRK F5cg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=to:subject:message-id:date:from:mime-version:dkim-signature; bh=PmXubv6zdOkFLR6jD5gLNamOJkqyQ4eeAFN+X9QA1bY=; fh=4rCG0PM8n0FOokGy8sSWDJpgPdCgp6yIXcpABJ7tUh0=; b=kfF+6Ts24gHvhf/88Dzh+pnPzGoBkEeUPmtEjjc40Ae5GmvjM9t9zMMUOgYzNauxkK e+AzUsBBxJa2Vxfl0DvCzt2mbvT0OEgTJ1OcDxUc5St6vT+fWgAubUGNIarnfo4PMvNm tcFb+54OisvtfxiUKnw2sIt//GzBTHh6NlXC5aA5gVEPEUXS8ZGnMf+0b074XcqWc9a7 x+Jw8IXa11HDPooQgNpSfXWucSA33xtsL5zLccipP3SmD1h0CETGkSFKCGCJ5KcMTHbs p0zV8X0O7UUc0WdaM9qIWVnAUlSUM/Bfasw/h9SmNVi70QAiv4kE4yviW4Bz7N4SaHDM uqpQ==; darn=lists.postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1769077587; x=1769682387; darn=lists.postgresql.org; h=to:subject:message-id:date:from:mime-version:from:to:cc:subject :date:message-id:reply-to; bh=PmXubv6zdOkFLR6jD5gLNamOJkqyQ4eeAFN+X9QA1bY=; b=RJ3r/u1q4crEeR+z6GN9hEJYEApoG8KxvK9SqvL2dT63ypfBEeflYcs2rQuX0PM+1a L79DdadmtzixAcOf3g4wg7MgkXJUPda+Ju6aUa9C74raWvHFlMHveLuV5bJKTxStcu06 pigORkmRZ2/Zh7Pgq4Ep4d1TpK/GPv+UkQN4OIi/8Sv6BFDZQNAEhHsEzzanPi6VhIKw T7sEH4z3TvSsowuPONciMHzHt2GdsI2AayRk3/FwFOxuOXW+ScMjICUlPi9/GDKqsjVZ Km3Apme3AcT/xwXwVaYUfAgs2DmvLbkI2rEvJw/200scW+ymKmuMXp1wwiF83t41G9Lh la0Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1769077587; x=1769682387; h=to:subject:message-id:date:from:mime-version:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=PmXubv6zdOkFLR6jD5gLNamOJkqyQ4eeAFN+X9QA1bY=; b=YO3bgLGbR3CWzcP1u0dQWML0vW/PyFm/HaaTygaZalJTjqmCGWfgzsLEcjUzVCfmkv /46W28Ew34r7xO2/JyrLC/PWgVViNm/BZHvUwTkfmdz+tAsJAwPAwvSeEhVwmK88+DC9 kQ5pe9fXj2k3PGsZ1IQm9ynzoMf2trNoyGM/e88bbn44CNdPueO/9OS7FXvQm3xPTBK9 lEL8s0K8bORW1Z4/PUviIToWJ+UFvtxo/UJBGwrgMSGJp0xbzSMoII607qLKG2AOSW7f 7OcfY28pH025OZmkhLgxgUiaiXXusJUiF3ruVEKs1rl1AmN2AcfKwxSFUtZwAnhLQLOE Bf9w== X-Gm-Message-State: AOJu0Yx/2fOFU9Be2H0PjtYAyOHA0SnXYfO1MBtkPx1p3vpVrF3YN7c3 r99NB+YdUZwhH2+rxdCd7aL53PlIYlkuydNrG6XDCnC/rW5JnxIWVTVyozIPwCwV8Q0olg2MiZp o6UyC7VOrcHf3rX1yGC668sesx+n/70SOpG3hEkA= X-Gm-Gg: AZuq6aLS1pd2UtyxMOQ5HhLtvG0/xVHtpmzLdnhMnbcdlJMuXws/D+NSnPuI7d+SKHP OdsieNMhhPllKqS6tLPek+MUjmby/u2Ufq+TjoMeH1KSBxPPP1Oh/ApFqAmPAeis4FBvHCj+wnt dzr7Iwn4vWl/Cpxk2M0cvQw659uX85xOivLI3Msxp2OYtAUphGISXduFOOtMwl1SlpmlaIVKKlf CRNWhabQwjMO0SapoYTK7twM/ND2otka4kEWplydsfrDe35crCJNmaQeXi+aENEstfOczbbTEMB 3Ia6FtNY X-Received: by 2002:a05:651c:3047:b0:383:246a:74ec with SMTP id 38308e7fff4ca-385a541d9c9mr25834921fa.18.1769077587179; Thu, 22 Jan 2026 02:26:27 -0800 (PST) MIME-Version: 1.0 From: =?UTF-8?B?0JDQvdC00YDQtdC5INCa0YDRi9C70L7RgdC+0LI=?= Date: Thu, 22 Jan 2026 13:26:15 +0300 X-Gm-Features: AZwV_QjNzyc4_DC0ffJfT89yoaHDh8XaGE-1VJQUyCSgZ3kVnS-jrvQ9NZ-TFv4 Message-ID: Subject: =?UTF-8?Q?=5BTool=5D_pg=2Dstatus_=E2=80=94_lightweight_microservice_for_ch?= =?UTF-8?Q?ecking_PostgreSQL_host_status?= To: pgsql-general@lists.postgresql.org Content-Type: multipart/alternative; boundary="00000000000029fc870648f7799a" List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --00000000000029fc870648f7799a Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi all! I'd like to share a small open=E2=80=91source project I've been working on: [pg-status](https://github.com/krylosov-aa/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=E2=80=91efficient, 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=E2=80=91host = setup where DNS failover was too slow, but it's also handy for proxy setups or custom load=E2=80=91balancing 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 --00000000000029fc870648f7799a Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi all!

I'd like to share a small open=E2=80=91= source project I've been working on: [pg-status](https://github.com/krylosov-aa/pg-status= ).

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

It's designed to run alongsi= de your main application. It's lightweight, resource=E2=80=91efficient,= and delivers high performance. You can query it on every request without n= oticeable overhead.

pg-status polls your database hosts in the backg= round 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=E2=80=91host setup where DNS fa= ilover was too slow, but it's also handy for proxy setups or custom loa= d=E2=80=91balancing logic.

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

Feedback and discussion are very welcome. I&#= 39;d love to hear your thoughts!

Best regards, =C2=A0
Andrei Kryl= osov
--00000000000029fc870648f7799a--