Re: Function to promote standby servers

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Ian Barwick <ian(at)2ndquadrant(dot)com>
Cc: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Function to promote standby servers
Date: 2018-10-26 04:51:24
Message-ID: 20181026045124.GC3909@paquier.xyz
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Oct 26, 2018 at 11:36:00AM +0900, Ian Barwick wrote:
> Documentation for this [*] says "Returns true if promotion is
> successful and false otherwise", which is not correct if "wait" is
> false, as it will always return TRUE.

Yes, in the case where the promotion has been initiated.

> + <literal>false</literal> otherwise. If <parameter>wait</parameter>
> + is set to <literal>false</literal>, the function returns <literal>true</literal>
> + immediately after sending the promotion signal to the postmaster.

Or we could use "the function returns true immediately after initiating
the promotion by sending the promotion signal to the postmaster"? As a
native speaker which one feels more natural to you?
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2018-10-26 04:52:34 Re: [PATCH] Tab complete EXECUTE FUNCTION for CREATE (EVENT) TRIGGER
Previous Message Pavel Stehule 2018-10-26 04:46:41 Re: PostgreSQL vs SQL/XML Standards