Received: from localhost (unknown [200.46.204.182]) by postgresql.org (Postfix) with ESMTP id 048209F9ACF for ; Mon, 17 Sep 2007 10:01:43 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.182]) (amavisd-maia, port 10024) with ESMTP id 54335-06 for ; Mon, 17 Sep 2007 10:01:27 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by postgresql.org (Postfix) with ESMTP id 2805D9F9AB9 for ; Mon, 17 Sep 2007 10:01:38 -0300 (ADT) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1IXGCg-0002br-W7 for pgsql-jdbc@postgresql.org; Mon, 17 Sep 2007 14:59:54 +0200 Received: from 83-244-179-210.cust-83.exponential-e.net ([83.244.179.210]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 17 Sep 2007 14:59:54 +0200 Received: from teknokrat by 83-244-179-210.cust-83.exponential-e.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 17 Sep 2007 14:59:54 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-jdbc@postgresql.org From: teknokrat Subject: Re: making the XARessource serializable Date: Mon, 17 Sep 2007 13:58:53 +0100 Lines: 34 Message-ID: References: <46EE5482.9060603@enterprisedb.com> <46EE6BDA.5020503@enterprisedb.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: 83-244-179-210.cust-83.exponential-e.net User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) In-Reply-To: <46EE6BDA.5020503@enterprisedb.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.348 tagged_above=0 required=5 tests=AWL=0.650, BAYES_00=-2.599, FORGED_YAHOO_RCVD=2.297 X-Spam-Level: X-Archive-Number: 200709/84 X-Sequence-Number: 17506 Heikki Linnakangas wrote: > teknokrat wrote: >> From what i have managed to make out, Arjuna has a xa recovery module >> that can recover resources if the XAResource is serializable. Things get >> more complicated if its not. I've recompiled the jdbc drivers, making >> PGXAConnection serializable and it worked. > > What exactly did you do to "make PGXAConnection serializable"? If you > just add "implements Serializable", you'll get an > NotSerializableException when you actually try to serialize it. > belive or not, thats exactly what i did. I thought that the BaseConnection instance would stuff things up but it hasn't. No idea why. >> This is a link illustrating >> the behaviour we were getting >> http://wiki.jboss.org/wiki/Wiki.jsp?page=TxNonSerializableXAResource > > According to that, you need to provide an implementation of > com.arjuna.ats.jta.recovery.XAResourceRecovery. Apparently there's a > simple implementation that looks up the XADataSource implementation with > JNDI. See JBoss Transaction API Programmers Guide, chapter 4, title > "Shipped XAResourceRecovery implementations". yeah, the JDBCXARecovery module. I guess I'll have to llok into that. The problem for us being that our password can't be in plaintext. > I'm surprised Arjuna/JBoss doesn't just connect to every database listed > in JNDI, or at least all those that were used in the transactions that > need recovery. That's what other app servers do, I believe. > that would be good.