[DB-SIG] Two-phase commit API proposal (was Re: Any standard for two phase commit APIs?)

Dieter Maurer dieter at handshake.de
Tue Jan 22 20:54:22 CET 2008


M.-A. Lemburg wrote at 2008-1-22 20:31 +0100:
> ...
>Branch ids are used for e.g. multiple connections of the same RM
>engaging in a global transaction. Each of those connections gets
>its own branch id.

But using multiple connections to the same RM seems to
be an error in the first place.

  Assume that a resource "R" is locked via connection "C1".
  Assume than that "R" is requested via connection "C2".

  If "C1 == C2", then the RM can see that the resource is already
  assigned to the connection and there is no blocking.

  Otherwise, the RM has not chance to recognize this and
  the request will be blocked until the transaction is commited
  or rolled back. There is quite a high chance, that since the
  "R" request is blocked, there will be no commit/roll back....



-- 
Dieter


More information about the DB-SIG mailing list