From: | "Drouvot, Bertrand" <bertranddrouvot(dot)pg(at)gmail(dot)com> |
---|---|
To: | shveta malik <shveta(dot)malik(at)gmail(dot)com>, Ajin Cherian <itsajin(at)gmail(dot)com> |
Cc: | "Zhijie Hou (Fujitsu)" <houzj(dot)fnst(at)fujitsu(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Peter Smith <smithpb2250(at)gmail(dot)com>, "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com>, Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, Ashutosh Sharma <ashu(dot)coek88(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
Subject: | Re: Synchronizing slots from primary to standby |
Date: | 2023-12-01 10:57:04 |
Message-ID: | bf89cea0-1046-41c6-a209-b65014d70bbf@gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
On 12/1/23 4:19 AM, shveta malik wrote:
> On Thu, Nov 30, 2023 at 5:37 PM Ajin Cherian <itsajin(at)gmail(dot)com> wrote:
>>
>>
>> 1. In my opinion, the second message "aborting the wait...moving to
>> the next slot" does not hold much value. There might not even be a
>> "next slot", there might be just one slot. I think the first LOG is
>> enough to indicate that the sync-slot is waiting as it repeats this
>> log till the slot catches up. I know these messages hold great value
>> for debugging but in production, "waiting..", "aborting the wait.."
>> might not be as helpful, maybe change it to debug?
>>
>> 2023-11-30 05:13:49.811 EST [6115] LOG: waiting for remote slot
>> "sub1" LSN (0/3047A90) and catalog xmin (745) to pass local slot LSN
>> (0/3047AC8) and catalog xmin (745)
>> 2023-11-30 05:13:57.909 EST [6115] LOG: aborting the wait for remote
>> slot "sub1" and moving to the next slot, will attempt creating it
>> again
>> 2023-11-30 05:14:07.921 EST [6115] LOG: waiting for remote slot
>> "sub1" LSN (0/3047A90) and catalog xmin (745) to pass local slot LSN
>> (0/3047AC8) and catalog xmin (745)
>>
>
> Sure, the message can be trimmed down. But I am not very sure if we
> should convert it to DEBUG. It might be useful to know what exactly is
> happening with this slot through the log file.Curious to know what
> others think here?
>
I think LOG is fine for the "waiting" one but I'd be tempted to put part of the
message in errdetail().
I think we could get rid of the "aborting" message (or move it to DEBUG). I mean
if one does not see the "newly locally created slot" message then I think it's
enough to guess the wait has been aborted or that it is still waiting.
But that's probably just a matter of taste.
Regards,
--
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2023-12-01 11:06:05 | Re: Synchronizing slots from primary to standby |
Previous Message | Shubham.Khanna@fujitsu.com | 2023-12-01 10:51:39 | RE: Remove unnecessary includes of system headers in header files |