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 7452777f-d7b1-f336-4882-b7802d79b9ab@oss.nttdata.com
Whole thread Raw
In response to Re: recovery_target_action=pause with confusing hint  ("movead.li@highgo.ca" <movead.li@highgo.ca>)
List pgsql-hackers

On 2020/04/08 16:41, movead.li@highgo.ca wrote:
> 
>  >> we should notice it in document I think.
>>There is the following explation about the relationship the recovery
>>pause and the promotion, in the document. You may want to add more
>>descriptions into the docs?
>  >------------------------------
>>If a promotion is triggered while recovery is paused, the paused
>>state ends and a promotion continues.
>>------------------------------
> 
> For example we can add this words:
> First-time pg_wal_replay_pause() called during recovery which triggered
> as promotion, pg_wal_replay_pause() show success but it did not really
> pause the recovery.

I think this is not true. In your case, pg_wal_replay_pause() succeeded
because the startup process had not detected the promotion request yet
at that moment.

To cover your case, what about adding the following description?

-----------------
There can be delay between a promotion request by users and the trigger of
a promotion in the server. Note that pg_wal_replay_pause() succeeds
during that delay, i.e., until a promotion is actually triggered.
-----------------

Regards,

-- 
Fujii Masao
Advanced Computing Technology Center
Research and Development Headquarters
NTT DATA CORPORATION



pgsql-hackers by date:

Previous
From: Pavel Borisov
Date:
Subject: [PATCH] RUM Postgres 13 patch
Next
From: Peter Eisentraut
Date:
Subject: Re: adding partitioned tables to publications