From: Oliver Jowett <oliver@opencloud.com>
To: Heikki Linnakangas <hlinnaka@iki.fi>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: XA support
Date: Fri, 01 Jul 2005 11:05:14 +1200
Message-ID: <42C47AAA.2010302@opencloud.com> (raw)
In-Reply-To: <Pine.OSF.4.61.0506302116360.45052@kosh.hut.fi>
References: <Pine.OSF.4.61.0506291920120.108382@kosh.hut.fi>
<42C31E54.20000@opencloud.com>
<Pine.OSF.4.61.0506302116360.45052@kosh.hut.fi>
Heikki Linnakangas wrote:
> This is essentially impossible with approach B, if the ... part uses the
> connection for some other xid. Otherwise, should work.
Right, I was thinking about implications for the other approaches.
> Note that the XA term "thread of control" actually means a connection in
> JTA terms. It doesn't make any difference which java thread does work.
> See JTA spec, section 3.4.3.
Ah, ok, that makes a lot more sense then :-)
> I'm leaning towards approach C myself [...]
Blocking seems really dangerous :( It seems quite likely that you could
deadlock against yourself..
> since it's the simplest to
> implement and doesn't cause any unexpected prepares.
Yeah, I thought some more about that and B is really bad from the
unexpected prepare angle. If we're preparing before the TM asks us to
(and therefore have transaction showing up as prepared in recovery) it
seems possible that a TM will incorrectly decide to commit those after
recovery.
> Or possibly even violating the spec and not allowing to start another transaction before the previous one has been prepared.
This actually sounds like the best thing now as it produces obvious,
easy-to-diagnose errors when you do something that the driver doesn't
yet support.
-O
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: oliver@opencloud.com, hlinnaka@iki.fi
Subject: Re: XA support
In-Reply-To: <42C47AAA.2010302@opencloud.com>
References: <Pine.OSF.4.61.0506291920120.108382@kosh.hut.fi> <42C31E54.20000@opencloud.com> <Pine.OSF.4.61.0506302116360.45052@kosh.hut.fi> <42C47AAA.2010302@opencloud.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox