Re: [EXTERNAL] Re: Add non-blocking version of PQcancel

From: Jelte Fennema-Nio <postgres(at)jeltef(dot)nl>
To: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Cc: vignesh C <vignesh21(at)gmail(dot)com>, Thomas Munro <thomas(dot)munro(at)gmail(dot)com>, Denis Laxalde <denis(dot)laxalde(at)dalibo(dot)com>, Greg Stark <stark(at)mit(dot)edu>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "Gregory Stark (as CFM)" <stark(dot)cfm(at)gmail(dot)com>, Jelte Fennema <Jelte(dot)Fennema(at)microsoft(dot)com>, Daniel Gustafsson <daniel(at)yesql(dot)se>, Peter Eisentraut <peter(at)eisentraut(dot)org>, Andres Freund <andres(at)anarazel(dot)de>, Justin Pryzby <pryzby(at)telsasoft(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: [EXTERNAL] Re: Add non-blocking version of PQcancel
Date: 2024-01-26 16:52:45
Message-ID: CAGECzQR80k0OMCS+AC08r_rw1w3rvie-1TrZ2zTUB-mPs9uTTw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, 26 Jan 2024 at 13:11, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> wrote:
> I wonder, would it make sense to put all these new functions in a
> separate file fe-cancel.c?

Okay I tried doing that. I think the end result is indeed quite nice,
having all the cancellation related functions together in a file. But
it did require making a bunch of static functions in fe-connect
extern, and adding them to libpq-int.h. On one hand that seems fine to
me, on the other maybe that indicates that this cancellation logic
makes sense to be in the same file as the other connection functions
(in a sense, connecting is all that a cancel request does).

Attachment Content-Type Size
v26-0005-Start-using-new-libpq-cancel-APIs.patch application/octet-stream 10.5 KB
v26-0002-libpq-Add-pq_release_conn_hosts-function.patch application/octet-stream 2.5 KB
v26-0003-libpq-Change-some-static-functions-to-extern.patch application/octet-stream 9.7 KB
v26-0001-libpq-Move-cancellation-related-functions-to-fe-.patch application/octet-stream 26.5 KB
v26-0004-Add-non-blocking-version-of-PQcancel.patch application/octet-stream 44.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Melanie Plageman 2024-01-26 17:06:30 Re: Emit fewer vacuum records by reaping removable tuples during pruning
Previous Message Alvaro Herrera 2024-01-26 16:48:02 Re: Supporting MERGE on updatable views