Re: Named transaction - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Named transaction
Date
Msg-id 5998.1245279806@sss.pgh.pa.us
Whole thread Raw
In response to Re: Named transaction  (Andrew Dunstan <andrew@dunslane.net>)
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> According to the (hard to find) Firebird docs (or rather, the old 
> Interbase docs, which is all they have):

>     A single application can start simultaneous transactions. InterBase
>     extends transaction
>     management and data manipulation statements to support transaction
>     names, unique
>     identifiers that specify which transaction controls a given
>     statement among those
>     transactions that are active.

Hmm.  Okay, that squares with what the OP mentioned about being able to
emulate it with multiple connections --- basically, he wants to
service multiple concurrent transactions using just a single backend and
client connection.

I can't see us trying to support that ... if you think making the
backend thread-safe is a daunting project, this is ten times worse.
It would mean making *all* transaction-local storage anonymous instead
of being able to use static variables.  I suspect the serial nature
of our FE/BE protocol would get in your way pretty darn quick, too,
unless it's okay to not be able to switch to another one of the
transactions while the one you just issued a command to remains busy.

Just use multiple connections.  That gets the job done today.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Cannot use all four trigger events at once
Next
From: "Greg Sabino Mullane"
Date:
Subject: Re: Cannot use all four trigger events at once