On Wed, Dec 15, 2021 at 9:42 AM Kyotaro Horiguchi
<horikyota.ntt@gmail.com> wrote:
>
> At Tue, 14 Dec 2021 19:31:21 +0530, Ashutosh Bapat <ashutosh.bapat.oss@gmail.com> wrote in
> > On Tue, Dec 14, 2021 at 9:35 AM Kyotaro Horiguchi
> > <horikyota.ntt@gmail.com> wrote:
> > > > [17605] LOG: terminating process 17614 to release replication slot "s1"
> > > + [17605] DETAIL: The slot's restart_lsn 0/2C0000A0 exceeds max_slot_wal_keep_size.
> > > > [17614] FATAL: terminating connection due to administrator command
> > > > [17605] LOG: invalidating slot "s1" because its restart_lsn 0/2C0000A0 exceeds max_slot_wal_keep_size
> > >
> > > Somewhat the second and fourth lines look inconsistent each other but
> > > that wouldn't be such a problem. I don't think we want to concatenate
> > > the two lines together as the result is a bit too long.
> > >
> > > > LOG: terminating process 17614 to release replication slot "s1" because it's restart_lsn 0/2C0000A0 exceeds
max_slot_wal_keep_size.
> > >
> > > What do you think about this?
> >
> > Agree. I think we should also specify the restart_lsn value which
> > would be within max_slot_wal_keep_size for better understanding.
>
> Thanks! It seems to me the main message of the "invalidating" log has
> no room for further detail. So I split the reason out to DETAILS line
> the same way with the "terminating" message in the attached second
> patch. (It is separated from the first patch just for review) I
> believe someone can make the DETAIL message simpler or more natural.
>
> The attached patch set emits the following message.
>
> > LOG: invalidating slot "s1"
> > DETAIL: The slot's restart_lsn 0/10000D68 is behind the limit 0/11000000 defined by max_slot_wal_keep_size.
>
> The second line could be changed like the following or anything other.
>
> > DETAIL: The slot's restart_lsn 0/10000D68 got behind the limit 0/11000000 determined by max_slot_wal_keep_size.
> .....
>
The second version looks better as it gives more details. I am fine
with either of the above wordings.
I would prefer everything in the same message though since
"invalidating slot ..." is too short a LOG message. Not everybody
enabled details always.
--
Best Wishes,
Ashutosh Bapat