Re: terms for database replication: synchronous vs eager - Mailing list pgsql-hackers

From Markus Schiltknecht
Subject Re: terms for database replication: synchronous vs eager
Date
Msg-id 46EAAF9C.3040200@bluegap.ch
Whole thread Raw
In response to Re: terms for database replication: synchronous vs eager  (Chris Browne <cbbrowne@acm.org>)
List pgsql-hackers
Hi,

Chris Browne wrote:
> The approach that was going to be taken, in Slony-II, to apply locks
> as early as possible so as to find conflicts as soon as possible,
> rather than waiting, seems "eager" to me.

Agreed. WRT locking, one might also call it "pessimistic", but that 
sounds so... negative.

I find the "as soon as possible" bit rather weak, instead it's exactly 
"before the origin node confirms commit". Of course only conflicts which 
could possibly lead to an abort of the transaction in question are taken 
into account. A possible definition may be:
  "Eager replication systems do only confirm the commit of a transaction   after they have checked for cross-node
conflicts,which could require   the transaction to abort.  (While lazy systems may confirm the commit   before)."
 

Note how much less restrictive that definition is, that that of a fully 
synchronous system.
> But I'm not sure to what extent that notion has been drawn into the> Postgres-R work...

My current variant of Postgres-R goes the very same path, using MVCC 
instead of locking wherever possible (with the very same effect, but 
allowing more concurrency :-) ).

Regards

Markus



pgsql-hackers by date:

Previous
From: "Don Walker"
Date:
Subject: Use of global and static variables in shared libraries
Next
From: Josh Berkus
Date:
Subject: Re: RETURNING and DO INSTEAD ... Intentional or not?