Re: recovery_target_action=pause with confusing hint - Mailing list pgsql-hackers

From Fujii Masao
Subject Re: recovery_target_action=pause with confusing hint
Date
Msg-id 2f616e51-0bd6-b983-b3f7-d8943b21b7ba@oss.nttdata.com
Whole thread Raw
In response to Re: recovery_target_action=pause with confusing hint  (Fujii Masao <masao.fujii@oss.nttdata.com>)
List pgsql-hackers

On 2020/04/01 19:37, Fujii Masao wrote:
> 
> 
> On 2020/04/01 18:56, movead.li@highgo.ca wrote:
>>
>>  >This happens because the startup process detects the trigger file
>>> after pg_wal_replay_pause() succeeds, and then make the recovery
>>> get out of the paused state.
>> Yes that is.
>>
>>  >It might be problematic to end the paused
>>> state silently? So, to make the situation less confusing, what about
>>> emitting a log message when ending the paused state because of
>>> the promotion?
>> But where to emit it? I think it not so good by emitting to log file,
>> because the user will not check it everytime.
> 
> Yeah, I'm thinking to emit the message to log file, like the startup process
> does in other places :)

So I'd like to propose the attached patch. The patch changes the message
logged when a promotion is requested, based on whether the recovery is
in paused state or not.

Regards,

-- 
Fujii Masao
NTT DATA CORPORATION
Advanced Platform Technology Group
Research and Development Headquarters

Attachment

pgsql-hackers by date:

Previous
From: Amit Kapila
Date:
Subject: Re: WAL usage calculation patch
Next
From: Alexander Korotkov
Date:
Subject: Re: [PATCH] Opclass parameters