Re: Named transaction

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Pavel Golub <pavel(at)gf(dot)microolap(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Named transaction
Date: 2009-06-17 23:03:26
Message-ID: 5998.1245279806@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Andrew Dunstan <andrew(at)dunslane(dot)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

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Greg Sabino Mullane 2009-06-18 00:45:45 Re: [HACKERS] Cannot use all four trigger events at once
Previous Message Tom Lane 2009-06-17 22:50:30 Re: [HACKERS] Cannot use all four trigger events at once