Files
substrate/cmd
Benjamin Elder 8f3b500fbc atepg: re-read the client certificate for every new connection
pgx resolves sslcert, sslkey and sslrootcert while it parses the
connection string and pins the result for the life of the pool. Those
paths are projected pod certificates that the kubelet replaces about
every day, so ate-api-server kept presenting the certificate it started
with; postgres verifies client certificates, so once that one expired it
would refuse every new connection the pool made.

Re-parse the connection string in BeforeConnect, which pgxpool calls with
the per-connection copy of the config it is about to dial with. That
costs one small file read per new connection and covers the trust bundle
as well as the client certificate.
2026-08-24 22:00:04 -07:00
..