Re: protocol change in 7.4 - Mailing list pgsql-hackers

From Satoshi Nagayasu
Subject Re: protocol change in 7.4
Date
Msg-id 200211050605.gA565tD17709@penguin.bioinfo.sfc.keio.ac.jp
Whole thread Raw
In response to Re: protocol change in 7.4  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: protocol change in 7.4  (Hannu Krosing <hannu@tm.ee>)
List pgsql-hackers
Tom Lane wrote:
> I don't see why 2PC would require any protocol-level change.  I would
> think that the API would be something like
> 
>     BEGIN;
>     issue some commands ...
>     PRECOMMIT;
>     -- if the above does not return an error, then
>     COMMIT;
> 
> In other words, 2PC would require some new commands, but a new command
> doesn't affect the protocol layer.

I think a precommit-vote-commit phase of 2PC can be implemented in
command-lavel or protocol-level.

In command-level 2PC, an user application (or application programmer)
must know the DBMS is clustered or not (to use PRECOMMIT command).

In protocol-layer 2PC, no new SQL command is required.
A precommit-vote-commit phase will be called implicitly.  It means an
user application can be used without any modification.  An application
can use a traditional way (BEGIN...COMMIT).

So I made my decision to use protocol-layer implementation.
It doesn't affect the SQL command layer.

-- 
NAGAYASU Satoshi <snaga@snaga.org>


pgsql-hackers by date:

Previous
From: Neil Conway
Date:
Subject: Re: PostgreSQL IRC Channel... who's the Admin?
Next
From: Thomas Lockhart
Date:
Subject: Re: v7.3Beta4 Tag'd and Packaged ...