A ref change was pushed to the repository containing the project "Postgres-XC: write-scalable synchronous multi-master PostgreSQL cluster".
The branch, master has been updated
via b7a07756ccd276e1138a0949d0b7400832099b09 (commit)
from 48fb54b318a3efd41fae3d97c5baf5c35190d9e2 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit b7a07756ccd276e1138a0949d0b7400832099b09
Author: Mason S <mas...@ma...>
Date: Fri Apr 9 10:17:20 2010 -0400
For writes to replicated tables, use primary copy technique to reduce
the likelihood of distributed deadlocks. That is, if all writes
for a table first go through the same data node, if the same tuple is
updated by multiple clients, we can at least ensure that the first
session that obtains the lock can similarly obtain the lock for
the same tuple on all of the nodes. (Usual deadlocks are still
possible.)
There is a new GUC parameter, primary_data_node. By default it is 1,
the node number where to execute writes to replicated tables first,
before doing the other ones. If it is set to 0, then the primary
node technique is not used, and it will update all replicas
simultaneously.
Instead of the planner returning a list of nodes to execute on,
it returns a pointer to Exec_Nodes, which contains the primary and
secondary nodes to execute on. DataNodeExec() now uses this information.
I also added a new check so that if a different number of rows were
affected on replicated tables (an UPDATE, for example), an error occurs.
This happens for COMBINE_TYPE_SAME. (I tested with the help of EXECUTE
DIRECT, intentionally messing up the data.)
-----------------------------------------------------------------------
Summary of changes:
src/backend/pgxc/locator/locator.c | 64 +++++----
src/backend/pgxc/plan/planner.c | 75 ++++++-----
src/backend/pgxc/pool/combiner.c | 20 +++-
src/backend/pgxc/pool/datanode.c | 180 ++++++++++++++++++++++---
src/backend/tcop/postgres.c | 13 +-
src/backend/utils/misc/guc.c | 9 ++
src/backend/utils/misc/postgresql.conf.sample | 3 +
src/include/pgxc/combiner.h | 2 +-
src/include/pgxc/datanode.h | 4 +-
src/include/pgxc/locator.h | 15 ++-
src/include/pgxc/planner.h | 5 +-
11 files changed, 299 insertions(+), 91 deletions(-)
hooks/post-receive
--
Postgres-XC: write-scalable synchronous multi-master PostgreSQL cluster
|