From: | Heikki Linnakangas <hlinnaka(at)iki(dot)fi> |
---|---|
To: | Tristan Partin <tristan(at)neon(dot)tech> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org, Shlok Kyal <shlok(dot)kyal(dot)oss(at)gmail(dot)com> |
Subject: | Re: psql not responding to SIGINT upon db reconnection |
Date: | 2023-11-16 14:33:52 |
Message-ID: | 5e28b89f-0033-4e42-8184-b71b731c1aa2@iki.fi |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 06/11/2023 19:16, Tristan Partin wrote:
>>> That sounds like a much better solution. Attached you will find a v4
>>> that implements your suggestion. Please let me know if there is
>>> something that I missed. I can confirm that the patch works.
This patch is missing a select(). It will busy loop until the connection
is established or cancelled.
Shouldn't we also clear CancelRequested after we have cancelled the
attempt? Otherwise, any subsequent attempts will immediately fail too.
Should we use 'cancel_pressed' here rather than CancelRequested? To be
honest, I don't understand the difference, so that's a genuine question.
There was an attempt at unifying them in the past but it was reverted in
commit 5d43c3c54d.
--
Heikki Linnakangas
Neon (https://neon.tech)
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2023-11-16 15:06:38 | Re: BUG #18097: Immutable expression not allowed in generated at |
Previous Message | Heikki Linnakangas | 2023-11-16 14:03:46 | Re: [HACKERS] Should logtape.c blocks be of type long? |