| Author |
Arjuna Transaction with Jboss
|
Rajasekhar Bandapalle
Greenhorn
Joined: Aug 13, 2008
Posts: 5
|
|
Hi, I am using the Arjuna transaction with Jboss for achieving the two phase commit protocol and my code is looks like below: <bean id="transactionManagerImple" class="com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionManagerImple"/> <bean id="jtaTransactionManager" class="org.springframework.transaction.jta.JtaTransactionManager"> <property name="transactionManager"> <ref bean="transactionManagerImple"/> </property> </bean> <bean id="myOfferAdminManagerTarget" class="com.directgroup.offeradmin.service.offer.OfferAdminManagerImpl"> <property name="offerAdminDevFactory" ref="offerAdminDevFactory" /> <property name="offerAdminQaFactory" ref="offerAdminQaFactory" /> </bean> <bean id="myProductService" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean"> <property name="transactionManager"> <ref bean="jtaTransactionManager"/> </property> <property name="target"> <ref bean="myOfferAdminManagerTarget"/> </property> <property name="transactionAttributes"> <props> <prop key="save*">PROPAGATION_REQUIRED</prop> </props> </property> </bean> While deploying the my app and getting the following exception: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'jtaTransacti onManager' defined in ServletContext resource [/WEB-INF/dispatch-servlet.xml]: Error setting propert y values; nested exception is org.springframework.beans.PropertyBatchUpdateException; nested Propert yAccessExceptions (1) are: PropertyAccessException 1: org.springframework.beans.TypeMismatchException: Failed to convert proper ty value of type [com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionManagerImple] to req uired type [javax.transaction.TransactionManager] for property 'transactionManager'; nested exceptio n is java.lang.IllegalArgumentException: Cannot convert value of type [com.arjuna.ats.internal.jta.t ransaction.arjunacore.TransactionManagerImple] to required type [javax.transaction.TransactionManage r] for property 'transactionManager': no matching editors or conversion strategy found at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropert yValues(AbstractAutowireCapableBeanFactory.java:1201) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean (AbstractAutowireCapableBeanFactory.java:940) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean (AbstractAutowireCapableBeanFactory.java:437) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory$1.run(Abstra ctAutowireCapableBeanFactory.java:383) at java.security.AccessController.doPrivileged(Native Method) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(A bstractAutowireCapableBeanFactory.java:353) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFac tory.java:245) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(Defau ltSingletonBeanRegistry.java:169) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory .java:242) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory .java:164) at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingle tons(DefaultListableBeanFactory.java:400) at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitializ ation(AbstractApplicationContext.java:736) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicatio nContext.java:369) even configuration is also looks fine. Could any one please help me out ? Thanks, Rajasekhar. Edited by Jaikiran: Removed the email id. UseTheForumNotEmail [ August 21, 2008: Message edited by: Jaikiran Pai ]
|
 |
Santosh Ramachandrula
Ranch Hand
Joined: Apr 04, 2004
Posts: 252
|
|
Though old post thought if someone else runs into same issue it may help them (I ran into this issue yesterday).
I had a simillar issue on my JBOSS/spring/hibernate startup. Turns out that there are two versions of javax.user.TransactionManager(one jta-1.1.jar from hibernate and other jbossjta.jar from jboss/arjuna). Since Jboss is using Arjuna I removed jta-1.1.jar and server startup/loading the spring context file worked fine after that.
|
Thanks,
Santosh
|
 |
 |
|
|
subject: Arjuna Transaction with Jboss
|
|
|