Re: Allow specifying a dbname in pg_basebackup connection string

Jelte Fennema-Nio <postgres@jeltef.nl>

From: Jelte Fennema <postgres@jeltef.nl>
To: Euler Taveira <euler@eulerto.com>
Cc: Thom Brown <thom@linux.com>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2023-07-05T15:50:01Z
Lists: pgsql-hackers
On Wed, 5 Jul 2023 at 16:01, Euler Taveira <euler@eulerto.com> wrote:
> One of the PgBouncer's missions is to be a transparent proxy.
>
> Sometimes you cannot reach out the database directly due to a security policy.

Indeed the transparent proxy use case is where replication through
pgbouncer makes sense. There's quite some reasons to set up PgBouncer
like such a proxy apart from security policies. Some others that come
to mind are:
- load balancer layer of pgbouncers
- transparent failovers
- transparent database moves

And in all of those cases its nice for a user to use a single
connection string/hostname. Instead of having to think: Oh yeah, for
backups, I need to use this other one.



Commits

  1. pg_basebackup, pg_receivewal: fix failure to find password in ~/.pgpass.

  2. Allow dbname in pg_basebackup/pg_receivewal connstring