<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>On 21 Jan 2011, at 17:15, Mircea Markus wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div><br>On 21 Jan 2011, at 16:34, Galder Zamarreņo wrote:<br><br><blockquote type="cite">Hi,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Re: <a href="https://issues.jboss.org/browse/ISPN-845">https://issues.jboss.org/browse/ISPN-845</a><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">This is causing issues with use cases such as the Hibernate 2LC. Imagine this scenario:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">tx.begin();<br></blockquote><blockquote type="cite">cache1.get();<br></blockquote><blockquote type="cite">cache2.put();<br></blockquote><blockquote type="cite">cache3.remove();<br></blockquote><blockquote type="cite">tx.commit();<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">At commit time, 3 prepares are generated of which, the 1st prepare is marked as readonly (no mods made on cache1), so that prepare is committed in advance.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Now, when tx.commit() is called it fails cos the first tx for cache1 has already been committed.<br></blockquote>I guess this is because the XAResource doesn't find the tx in the transaction table. I guess the way to go is to delist it after committing, let me ping Jonathan to see :)<br> if (trace) log.trace("no tx found for {0}", xid);<br> throw new XAException(XAException.XAER_NOTA);<font class="Apple-style-span" color="#006312"><br></font></div></blockquote><br></div><div>What TM are you using?</div><div>I've just confirmed with Jonathan - according to XA spec, the TM should NOT call commit on a resource that has answered Readonly from the prepare.</div><br></body></html>