From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Andres Freund <andres(at)anarazel(dot)de> |
Cc: | Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org |
Subject: | Re: Walsender may fail to send wal to the end. |
Date: | 2021-03-29 05:47:33 |
Message-ID: | YGFp9fxaWg/kw0OF@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Mar 26, 2021 at 10:16:40AM -0700, Andres Freund wrote:
> Hi,
>
> On 2021-03-26 18:20:14 +0900, Kyotaro Horiguchi wrote:
> > This is because XLogSendPhysical detects removal of the wal segment
> > currently reading by shutdown checkpoint. However, there' no fear of
> > overwriting of WAL segments at the time.
> >
> > So I think we can omit the call to CheckXLogRemoved() while
> > MyWalSnd->state is WALSNDSTTE_STOPPING because the state comes after
> > the shutdown checkpoint completes.
> >
> > Of course that doesn't help if walsender was running two segments
> > behind. There still could be a small window for the failure. But it's
> > a great help to save the case of just 1 segment behind.
>
> -1. This seems like a bandaid to make a broken configuration work a tiny
> bit better, without actually being meaningfully better.
Agreed. Still, wouldn't it be better to avoid such configurations and
protect a bit things with a check on the new value?
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2021-03-29 06:12:43 | Re: [PATCH] Provide more information to filter_prepare |
Previous Message | Peter Smith | 2021-03-29 05:16:40 | Re: name of enum used in 'Cache if PathTarget and RestrictInfos contain volatile functions' |