Hi Fujii-San, Joao,

Thank you both for the review, and Joao for the detailed testing.

> Thanks for the patch! It looks good to me.
>
> We should backpatch it to all supported versions? If so, for v17 and older,
> ProcessWalRcvInterrupts() should be called instead of CHECK_FOR_INTERRUPTS()?

Yes, I agree that this should be backpatched to all supported branches.

For v17 and older, ProcessWalRcvInterrupts() is the appropriate check.
Besides calling CHECK_FOR_INTERRUPTS(), it also handles the receiver’s
shutdown flag, so CHECK_FOR_INTERRUPTS() alone would not be
sufficient.

>From v18 onward, the WAL receiver uses the standard die() SIGTERM
handler, which sets InterruptPending and ProcDiePending. Termination
is therefore handled through the normal interrupt machinery, making
CHECK_FOR_INTERRUPTS() sufficient.

Best Regards,
Nitin Jadhav
Microsoft


Reply via email to