From: | Craig Ringer <craig(at)2ndquadrant(dot)com> |
---|---|
To: | "Inoue, Hiroshi" <inoue(at)tpf(dot)co(dot)jp> |
Cc: | "pgsql-odbc(at)postgresql(dot)org" <pgsql-odbc(at)postgresql(dot)org> |
Subject: | Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions |
Date: | 2014-06-26 08:23:27 |
Message-ID: | 53ABD87F.2030204@2ndquadrant.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-odbc |
On 06/25/2014 10:26 PM, Craig Ringer wrote:
> On 06/24/2014 11:07 AM, Craig Ringer wrote:
>> On 06/24/2014 05:23 AM, Inoue, Hiroshi wrote:
>>>
>>> XARMCreate() triggers xa_open() ( and xa_close()) probably so as to
>>> check that the XADLL works. Currently xa_open() doesn't connect to
>>> the database and simply saves the connection information for subsequent
>>> xa_commit(), xa_rollback() or xa_recover() call. When original process
>>> finished COMMIT/ROLLBACK PREPARED properly, No database access occurs
>>> in msdtc process. We can change xa_open() so that it connects to the
>>> database immediately and causes an error to XARMCreate() when the
>>> connection fails.
>>
>> That's enlightening. Thankyou very much.
>>
>> I'll happily implement that and send in a patch. It may take a week or
>> two as I have some other projects on the boil, but hopefully it won't
>> take super long.
>
> ... and done.
>
> Please merge branch fix-syswow64-msdtc from my repo at
> https://github.com/ringerc/psqlODBC.git .
>
> see: https://github.com/ringerc/psqlODBC/pull/2
>
> Patch attached if you prefer that. See patch header and in-code comments
> for details.
Here's the revised patch. I've tested this against the customer's
original test case and it now runs properly. MSDTC correctly recovers
abandoned tx's in which Phase I commit succeeded then the app exited /
crashed before Phase II completed on one or both sessions.
Updated patch attached:
git am -s 0001-Fix-driver-name-mismatch-between-32-bit-ODBC-app-and.patch
or pull my branch, above.
--
Craig Ringer http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
Attachment | Content-Type | Size |
---|---|---|
0001-Fix-driver-name-mismatch-between-32-bit-ODBC-app-and.patch | text/x-patch | 4.4 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Heikki Linnakangas | 2014-06-26 08:23:37 | Re: Not sure if this crash is in psql odbc driver? |
Previous Message | Craig Ringer | 2014-06-26 08:15:59 | Re: Git history author/committer fields (was Re: msdtc with 32-bit app fails to resolve in-doubt or not-notifed transactions) |