Thread: PREPARE TRANSACTION compatibility?

PREPARE TRANSACTION compatibility?

From
Peter Eisentraut
Date:
The commands PREPARE TRANSACTION, COMMIT PREPARED, and ROLLBACK PREPARED
are the only ones that do not have a Compatibility section on their
reference page.  Does anyone remember whether they were our invention or
copied from or inspired by some other implementation?




Re: PREPARE TRANSACTION compatibility?

From
Heikki Linnakangas
Date:
On 13.04.2012 21:43, Peter Eisentraut wrote:
> The commands PREPARE TRANSACTION, COMMIT PREPARED, and ROLLBACK PREPARED
> are the only ones that do not have a Compatibility section on their
> reference page.  Does anyone remember whether they were our invention or
> copied from or inspired by some other implementation?

They are our invention.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


Re: PREPARE TRANSACTION compatibility?

From
Tom Lane
Date:
Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
> On 13.04.2012 21:43, Peter Eisentraut wrote:
>> The commands PREPARE TRANSACTION, COMMIT PREPARED, and ROLLBACK PREPARED
>> are the only ones that do not have a Compatibility section on their
>> reference page.  Does anyone remember whether they were our invention or
>> copied from or inspired by some other implementation?

> They are our invention.

Entirely?  I'm quite sure I remember some discussion about compatibility
of the prepared-transaction GIDs.  There must be at least part of that
API that's standard.
        regards, tom lane


Re: PREPARE TRANSACTION compatibility?

From
Heikki Linnakangas
Date:
On 13.04.2012 22:02, Tom Lane wrote:
> Heikki Linnakangas<heikki.linnakangas@enterprisedb.com>  writes:
>> On 13.04.2012 21:43, Peter Eisentraut wrote:
>>> The commands PREPARE TRANSACTION, COMMIT PREPARED, and ROLLBACK PREPARED
>>> are the only ones that do not have a Compatibility section on their
>>> reference page.  Does anyone remember whether they were our invention or
>>> copied from or inspired by some other implementation?
>
>> They are our invention.
>
> Entirely?  I'm quite sure I remember some discussion about compatibility
> of the prepared-transaction GIDs.  There must be at least part of that
> API that's standard.

There's the X/Open standard, and the Java Transaction API (JTA) standard 
that's based on it. There's probably other specs for other languages, 
but those two are what I've looked at. The specs define the client-side 
interface, but they don't say anything about the client-server protocol.

X/Open and JTA have the concept of GIDs, called Xids in the JDBC 
nomenclature. IIRC they have a certain width, and consist of two parts, 
a transaction id, and a branch id. But from the server's point of view, 
the GIDs are just unique identifiers, assigned by the client (= 
transaction manager), with no further special meaning.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com