[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-1287) Problem with WAS ExtendedJTATransaction not available when using MDB

Purvin Patel (JIRA) noreply at atlassian.com
Sat Sep 5 15:58:17 EDT 2009


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1287?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=33910#action_33910 ] 

Purvin Patel commented on HHH-1287:
-----------------------------------

This fix is in version 3.2.0.alpha2 and not in alpha1 as mentioned above.

> Problem with WAS ExtendedJTATransaction not available when using MDB
> --------------------------------------------------------------------
>
>                 Key: HHH-1287
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1287
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: core
>    Affects Versions: 3.1
>         Environment: WAS 6.0.2
> Message Driven Bean (CMT)
> Websphere MQ 5.3
> Oracle 10g (thin XA driver)
>            Reporter: dave jackson
>            Assignee: Steve Ebersole
>             Fix For: 3.2.0.alpha1, 3.1.3
>
>
> I'm currently having problems with the WAS6 ExtendedJTATransaction when using an MDB to update the database. The problem does not occur when using CMT SSBs.
> It looks like the ExtendedJTATransaction is simply not available after the CMT completes and the WebSphereExtendedJTATransactionLookup class attempts to look it up at java:comp/websphere/ExtendedJTATransaction as part of the normal 'after completion' callback.
> The problem occurs when the afterCompletion callback event fires and the ConnectionManager.isAggressiveRelease() method is called from ConnectionManager.afterTransaction(). This attempts to check to see if a transaction is in progress. This test in fact causes the transaction manager to be created (together with a look up of the current transaction) The lookup of the ExtendedJTATransaction fails and the an exception is thrown (see stack trace below).
> Although there may be an inconsistency in the way that a SSB and MDB operate, It seems fair to say that the transaction may not be available if it has completed. A workaround is therefore requested.
> Stack trace:
> [15/12/05 11:07:49:303 GMT] 0000003f RegisteredSyn E   WTRN0074E: Exception caught from after_completion synchronization operation: org.hibernate.HibernateException: javax.naming.NameNotFoundException: Name comp/websphere not found in context "java:".
> 	at org.hibernate.transaction.WebSphereExtendedJTATransactionLookup$TransactionManagerAdapter$TransactionAdapter.<init>(WebSphereExtendedJTATransactionLookup.java:235)
> 	at org.hibernate.transaction.WebSphereExtendedJTATransactionLookup$TransactionManagerAdapter$TransactionAdapter.<init>(WebSphereExtendedJTATransactionLookup.java:215)
> 	at org.hibernate.transaction.WebSphereExtendedJTATransactionLookup$TransactionManagerAdapter.getTransaction(WebSphereExtendedJTATransactionLookup.java:163)
> 	at org.hibernate.util.JTAHelper.isTransactionInProgress(JTAHelper.java:36)
> 	at org.hibernate.jdbc.JDBCContext.isTransactionInProgress(JDBCContext.java:180)
> 	at org.hibernate.jdbc.ConnectionManager.isAggressiveRelease(ConnectionManager.java:142)
> 	at org.hibernate.jdbc.ConnectionManager.afterTransaction(ConnectionManager.java:189)
> 	at org.hibernate.jdbc.JDBCContext.afterTransactionCompletion(JDBCContext.java:213)
> 	at org.hibernate.transaction.CacheSynchronization.afterCompletion(CacheSynchronization.java:85)
> 	at org.hibernate.transaction.WebSphereExtendedJTATransactionLookup$1.invoke(WebSphereExtendedJTATransactionLookup.java:265)
> 	at $Proxy30.afterCompletion(Unknown Source)
> 	at com.ibm.ws.jtaextensions.SynchronizationCallbackWrapper.afterCompletion(SynchronizationCallbackWrapper.java:74)
> 	at com.ibm.ws.Transaction.JTA.RegisteredSyncs.distributeAfter(RegisteredSyncs.java(Compiled Code))
> 	at com.ibm.ws.Transaction.JTA.TransactionImpl.distributeAfter(TransactionImpl.java:3652)
> 	at com.ibm.ws.Transaction.JTA.TransactionImpl.postCompletion(TransactionImpl.java:3631)
> 	at com.ibm.ws.Transaction.JTA.TransactionImpl.internalCommit(TransactionImpl.java:2522)
> 	at com.ibm.ws.Transaction.JTA.TransactionImpl.stage2CommitProcessing(TransactionImpl.java:1609)
> 	at com.ibm.ws.Transaction.JTA.TransactionImpl.processCommit(TransactionImpl.java:1483)
> 	at com.ibm.ws.Transaction.JTA.TransactionImpl.commit(TransactionImpl.java:1414)
> 	at com.ibm.ws.Transaction.JTA.TranManagerImpl.commit(TranManagerImpl.java:236)
> 	at com.ibm.ws.Transaction.JTA.TranManagerSet.commit(TranManagerSet.java:157)
> 	at com.ibm.ejs.csi.TranStrategy.commit(TranStrategy.java:716)
> 	at com.ibm.ejs.csi.TranStrategy.postInvoke(TranStrategy.java:167)
> 	at com.ibm.ejs.csi.TransactionControlImpl.postInvoke(TransactionControlImpl.java:569)
> 	at com.ibm.ejs.container.EJSContainer.postInvoke(EJSContainer.java(Compiled Code))
> 	at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:102)
> 	at com.ibm.ejs.container.MDBWrapper.onMessage(MDBWrapper.java:127)
> 	at com.ibm.ejs.jms.listener.ServerSession.run(ServerSession.java:458)
> 	at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1455)
> Caused by: javax.naming.NameNotFoundException: Name comp/websphere not found in context "java:".
> 	at com.ibm.ws.naming.ipbase.NameSpace.getParentCtxInternal(NameSpace.java(Compiled Code))
> 	at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java(Compiled Code))
> 	at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java(Inlined Compiled Code))
> 	at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java(Compiled Code))
> 	at com.ibm.ws.naming.java.javaURLContextRoot.lookup(javaURLContextRoot.java(Compiled Code))
> 	at com.ibm.ws.naming.java.javaURLContextRoot.lookup(javaURLContextRoot.java(Compiled Code))
> 	at javax.naming.InitialContext.lookup(InitialContext.java(Compiled Code))
> 	at org.hibernate.transaction.WebSphereExtendedJTATransactionLookup$TransactionManagerAdapter$TransactionAdapter.<init>(WebSphereExtendedJTATransactionLookup.java:227)
> 	... 28 more

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the hibernate-issues mailing list