Announcement Announcement Module
Collapse
No announcement yet.
Websphere transaction management Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Websphere transaction management

    have been trying to switch from spring aop transaction management to spring aspecjt transaction management.

    My configuration goes like this
    application context

    <bean id="txMgr"
    class="org.springframework.transaction.jta.WebSphe reUowTransactionManager">
    </bean>
    <tx:annotation-driven transaction-manager="txMgr" mode="aspectj"/>


    My aop file has the aspect defined <aspect name="org.springframework.transaction.aspectj.Anno tationTransactionAspect" />

    I can see the required weaving going on fine.

    But the problem is when i run the app I am getting some error.

    The scenario is class a (already running in an outer transaction)-> class b method (uses @Transactional(propagation = Propagation.REQUIRES_NEW)).

    The issues seems to be when the transaction is being suspended I am getting the below errors? Any ideas on how to solve this>?

    Caused by: org.springframework.transaction.TransactionSuspens ionNotSupportedException: JtaTransactionManager needs a JTA TransactionManager for suspending a transaction: specify the 'transactionManager' or 'transactionManagerName' property
    at org.springframework.transaction.jta.JtaTransaction Manager.doJtaSuspend(JtaTransactionManager.java:92 9)
    at org.springframework.transaction.jta.JtaTransaction Manager.doSuspend(JtaTransactionManager.java:911)
    at org.springframework.transaction.support.AbstractPl atformTransactionManager.suspend(AbstractPlatformT ransactionManager.java:573)
    at org.springframework.transaction.support.AbstractPl atformTransactionManager.handleExistingTransaction (AbstractPlatformTransactionManager.java:418)
    at org.springframework.transaction.support.AbstractPl atformTransactionManager.getTransaction(AbstractPl atformTransactionManager.java:347)
    at org.springframework.transaction.interceptor.Transa ctionAspectSupport.createTransactionIfNecessary(Tr ansactionAspectSupport.java:335)
    at org.springframework.transaction.interceptor.Transa ctionAspectSupport.createTransactionIfNecessary(Tr ansactionAspectSupport.java:273)
    at org.springframework.transaction.aspectj.AbstractTr ansactionAspect.ajc$before$org_springframework_tra nsaction_aspectj_AbstractTransactionAspect$1$2a73e 96c(AbstractTransactionAspect.aj:63)

  • #2
    Similar issue raised in the past, but no solution

    http://forum.springsource.org/showth...-spring-bug-)&

    Comment


    • #3
      try using this
      <tx:jta-transaction-manager/>
      <tx:annotation-driven />

      instead:
      <bean id="txMgr"
      class="org.springframework.transaction.jta.WebSphe reUowTransactionManager">
      </bean>
      <tx:annotation-driven transaction-manager="txMgr" mode="aspectj"/>

      Comment

      Working...
      X