| From: | Kirill Reshke <reshkekirill(at)gmail(dot)com> |
|---|---|
| To: | Hannu Krosing <hannuk(at)google(dot)com> |
| Cc: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Dave Cramer <davecramer(at)postgres(dot)rocks> |
| Subject: | Re: Adding an extra byte to ReadyForQuery (B) to indicate HOLD cursors |
| Date: | 2025-11-28 13:28:15 |
| Message-ID: | CALdSSPiAjz8h772jUaV+Ea_h+yqeqmWdU4X5Vcz3FPsuw+a+Dw@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Fri, 28 Nov 2025 at 14:48, Hannu Krosing <hannuk(at)google(dot)com> wrote:
>
> Would it make sense to add one more byte ('H' ?) at the end of the
> ReadyForQuery backend message to indicate that there are cursors that
> live across transactions, so thet the connection pooler knows to not
> give the database connections to other clients while this is happening
> ?
This part is actually interesting when speaking about connection
proxying (pooling, e.g. pgbouncer, odyssey, pgpool-II)
If we can inform the client that his postgresql backend has some
session-level objects (like prepared statement, temp table, advisory
lock or cursor), this will be very helpful.
On the pooler side, you can reuse or not reuse connections between
different clients based on this single byte value.
--
Best regards,
Kirill Reshke
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Álvaro Herrera | 2025-11-28 13:29:04 | Re: headerscheck ccache support |
| Previous Message | Peter Eisentraut | 2025-11-28 13:20:25 | Re: Remove useless casting to the same type |