[pgpool-committers: 93] pgpool: Allow to have private cache of master node id. This is neccesar

Tatsuo Ishii ishii at postgresql.org
Sat Mar 24 12:33:45 JST 2012


Allow to have private cache of master node id. This is neccesary for
MASTER_CONNECTION macro and friends because when master goes down it
will immediately update the info on shared memory, which cause running
pgpool child to look into NULL pointer because the process does not
connect to the new master yet. The private cache returns the old
master node id and will avoid the situation. Per bug report
http://www.pgpool.net/mantisbt/view.php?id=5
backport from:
46386e8fc792beef592a1b90308ccd654bb949dd

Fix pool_start_query() so that it uses my_master_node_id for initial
virtual_master_node_id. Real master node could be changed while pgpool
is running in streaming replication mode. Before it assigned
REAL_MASTER_NODE_ID, which could have no connections after fail over
and cause segafult because there's no connection to it.
backport from:
d95cecac8ae73e735dee30ef6697b3d1adac2d52

Fix pool_setall_node_to_be_sent() to use private_backend_status.  It
is possible that while processing, the node is not usable any more.
backport from:
e045a737f33e71b3a28eaa9779cdb672756051cd

Branch
------
V3_1_STABLE

Details
-------
http://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=514a6ac34a2c710ec01feefe03ca5f2457fa511b

Modified Files
--------------
child.c              |    6 ++++--
main.c               |    1 +
pool.h               |    3 ++-
pool_query_context.c |   14 +++++++++-----
4 files changed, 16 insertions(+), 8 deletions(-)



More information about the pgpool-committers mailing list