Re: pg_basebackup: Always return valid temporary slot names

Daniel Gustafsson <daniel@yesql.se>

From: Daniel Gustafsson <daniel@yesql.se>
To: Nishant Sharma <nishant.sharma@enterprisedb.com>
Cc: Jelte Fennema <me@jeltef.nl>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Jim Jones <jim.jones@uni-muenster.de>
Date: 2023-09-05T09:39:26Z
Lists: pgsql-hackers
> On 5 Sep 2023, at 09:09, Nishant Sharma <nishant.sharma@enterprisedb.com> wrote:

> With this, I was thinking, isn't this a problem of pgbouncer filling
> be_pid with random bits? Maybe it should have filled the be_pid
> with a random positive integer instead of any integer as it
> represents a pid?

I'm inclined to agree that anyone sending a value which is supposed to
represent a PID should be expected to send a value which corresponds to the
format of a PID.

--
Daniel Gustafsson




Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. pg_basebackup: Generate valid temporary slot names under PQbackendPID()