Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-28 Thread Shaik Mohammad Mujeeb
> The entire point of having a wire protocol is that you can't/don't > need to detect that.  The short answer here is that this is > pgbouncer's bug and you should be nagging them to change, not us. Assuming we've requested the PgBouncer team to stop abusing the server_version parameter for

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Julien Rouhaud
On Wed, 28 May 2025, 07:21 Tom Lane, wrote: > Shaik Mohammad Mujeeb writes: > > So, I feel that if we can reliably detect when the backend is a > non-PostgreSQL server, it might be better to adjust the warning > accordingly, rather than relying on a client-server version comparison in > such cas

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Tom Lane
Shaik Mohammad Mujeeb writes: > So, I feel that if we can reliably detect when the backend is a > non-PostgreSQL server, it might be better to adjust the warning accordingly, > rather than relying on a client-server version comparison in such cases. The entire point of having a wire protocol is

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Shaik Mohammad Mujeeb
Also, let’s say hypothetically that PgBouncer had a version like 17.2 - matching the psql (client) major version. In that case, the warning wouldn’t be shown at all, which might not be accurate either. So, I feel that if we can reliably detect when the backend is a non-PostgreSQL server, it m

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Shaik Mohammad Mujeeb
> Anyway, I'm minus quite a lot on silencing this warning, because > it is telling you about real problems you are likely to hit. +1 I just wanted to clarify that the concern here isn’t about the warning itself being shown, but rather about the reason it conveys, which can be a bit misleading.

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Tom Lane
"David G. Johnston" writes: > On Tue, May 27, 2025 at 3:08 PM Tom Lane wrote: >> Yeah. I'd say the fundamental problem is that pgbouncer is abusing >> the server_version parameter, which will break plenty of things >> besides psql --- pg_dump for instance > They proxy over the real server infor

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread David G. Johnston
On Tue, May 27, 2025 at 3:08 PM Tom Lane wrote: > "David G. Johnston" writes: > > psql has zero awareness of pgbouncer or any other non-PostgreSQL server > you > > might be able to point it to and establish a successful connection. The > > lack of a warning previously is probably more incorrect

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Tom Lane
"David G. Johnston" writes: > psql has zero awareness of pgbouncer or any other non-PostgreSQL server you > might be able to point it to and establish a successful connection. The > lack of a warning previously is probably more incorrect than its presence > now. Yeah. I'd say the fundamental pr

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Euler Taveira
On Tue, May 27, 2025, at 3:41 PM, Shaik Mohammad Mujeeb wrote: > In my case, *pset.sversion* ends up being *12001* (due to PgBouncer v1.20.1), > and since that’s less than *90200*, the warning gets triggered, which feels > misleading. But I was wondering - does it really make sense to compare >

Re: Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread David G. Johnston
On Tue, May 27, 2025 at 11:41 AM Shaik Mohammad Mujeeb < mujeeb...@zohocorp.com> wrote: > After the commit cf0cab868a, introduced in PG15, I noticed that when > connecting to the 'pgbouncer' database via Pgbouncer, the following warning > is shown: > > psql (17.2, server 1.20.1/bouncer) > WARNING:

Clarification on warning when connecting to 'pgbouncer' database via Pgbouncer

2025-05-27 Thread Shaik Mohammad Mujeeb
Hi Hackers, I was hoping to get some clarification regarding a behaviour I observed while connecting to the special 'pgbouncer' database used for administering or monitoring Pgbouncer. After the commit cf0cab868a, introduced in PG15, I noticed that when connecting to the 'pgbouncer' databa