On Wed, Jun 19, 2019 at 04:08:44PM -0400, Alvaro Herrera wrote: > Ho ho .. you know what misled me into thinking that that would work? > Just look at the name of the test that failed, "asterisk comes before > another standby name". That doesn't seem to be what the test is > testing!
I agree that the wording is poor here. Perhaps a better description in the comment block would be "standby1 is selected as sync as it has the highest priority, and is followed by a second standby listed first in the WAL sender array, in this case standby2". We could change the description like that "second standby chosen as sync is the first one in WAL sender array". The follow-up test using '2(*)' is actually worse in terms of ordering dependency as all standbys could be selected. The last test with a quorum lookup on all the standbys is fine from this perspective thanks to the ORDER BY on application_name when doing the lookup of pg_stat_replication. -- Michael
signature.asc
Description: PGP signature