aspose file tools*
The moose likes Spring and the fly likes  Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: javax/transactio Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark " Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: javax/transactio" Watch " Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: javax/transactio" New topic
Author

Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: javax/transactio

pankaj semwal
Ranch Hand

Joined: Oct 07, 2008
Posts: 301

Hi,
I am trying to integration strut2 hibernate and spring
and my code is as follows.







But i am getting following error in my log file.

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userimplDAO' defined in file [D:\Apache Software Foundation\Tomcat 5.5\webapps\Test\WEB-INF\classes\applicationContext.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in file [D:\Apache Software Foundation\Tomcat 5.5\webapps\Test\WEB-INF\classes\applicationContext.xml]: Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: javax/transaction/TransactionManager
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:315)
at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)


Please tell me where i am wrong.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14688
    
  16

You need to put JTA's jar in your classpath. In Hibernate, the JAR should be under \lib\required.


[My Blog]
All roads lead to JavaRanch
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Initialization of bean failed; nested exception is java.lang.NoClassDefFoundError: javax/transactio