[pgpool-committers: 5945] pgpool: Fix check_replication_lag to not break auto_failback.

Tatsuo Ishii ishii at sraoss.co.jp
Mon Jul 29 16:41:51 JST 2019


Fix check_replication_lag to not break auto_failback.

Commit bbfe3adb broke auto_failback because it doesn't collect info
from pg_stat_replication for down node. This commit fix the breakage
and eliminate thinko:

- Do not count the number of active nodes since it is useful to show
  streaming replication status in "show pool_nodes" for all nodes which
  are actually active and running even if Pgpool-II thinks they are
  down regardless auto_failback is on or off.

- Call pg_stat_replication once, rather than call for each node.

Branch
------
master

Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=0f500ec69dc898f9e53f47648b85fd9dcb603cfa

Modified Files
--------------
src/streaming_replication/pool_worker_child.c | 78 ++++++++++++---------------
1 file changed, 33 insertions(+), 45 deletions(-)



More information about the pgpool-committers mailing list