java - Spring and Hibernate inside Axis2 inside Tomcat6 -


I am trying to create a web service base on axis2 (without a servicelettext). I have a code that works properly (Spring + Hebrietnet) and try putting it in AAR as mentioned here and do all the good work except Hibernate.

I have:

  & lt; Bean id = "datasourcecommon" class = "org.apache.commons.dbcp.basicDataSource" deleted-method = "off" & gt; & Lt; Property Name = "driverClassName" value = "oracle.jdbc.OracleDriver" /> & Lt; Property name = "url" value = "jdbc: oracle: oci: @xxxx" /> & Lt; Property name = "user name" value = "xxxx" /> & Lt; Property Name = "Password" Value = "xxxx" /> & Lt; Property Name = "Maxactive" value = "10" /> & Lt; Property Name = "Default Auto Comet" value = "False" /> & Lt; / Bean & gt; & Lt; Bean id = "hibernate session factory" class = "org.springframework.orm.hibernate3.LocalSessionFactoryBean" & gt; & Lt; Property Name = "Data Source" Riff = "Datasourcecomman" / & gt; & Lt; Property Name = "Mapping Location" & gt; & Lt; Price & gt; Classpath: xxxx.hbm.xml & lt; / Pricing & gt; & Lt; / Property & gt; & Lt; Property Name = "Hibernate Properties" & gt; & Lt; Theater Content & gt; & Lt; Prop key = "hibernate.dialect" & gt; Org.hibernate.dialect.Oracle10gDialect & lt; / Prop & gt; & Lt; / Theater & gt; & Lt; / Property & gt; & Lt; / Bean & gt; & Lt; Bean id = "hibernateDaoSupport" abstract = "true" square = "org.springframework.orm.hibernate3.support.HibernateDaoSupport" & gt; & Lt; Property Name = "sessionFactory" ref = "Hybrannet Sessions Factory" / & gt; & Lt; / Bean & gt; & Lt; Bean id = "transaction manager" category = "org.springframework.orm.hibernate3.HibernateTransactionManager" & gt; & Lt; Property Name = "sessionFactory" ref = "Hybrannet Sessions Factory" / & gt; & Lt; / Bean & gt;  

This file in the root of AAR.

I copy this aar-file into the c: \ Program Files / Apache Software Foundation \ Tomcat 6.0 \ webapps \ Axis2 \ WEB-INF \ services , but if I If I try to run the Tomcat server, then I get an error:

  org.springframework.beans.factory.BeanCreationException:  

class path resources Error making bean with 'hybrancetationfattinator' defined in [xxxx.context.xml]: Instantation of Bean failed; Nested exception org.springframework.beans.BeanInstantiationException: Could not extend the bean class [org.springframework.orm.hibernate3.LocalSessionFactoryBean]: the manufacturer threw an exception; The nested exception is made by java.lang.NoClassDefFoundError ...: java.lang.ClassNotFoundException: org.hibernate.cfg.config.conf




Where's my fault?

If there is an error

Java.lang. ClassNotFoundException: org.hibernate.cfg.configuration

Then the mistake is that you did not include the hibernate class (hibernated jarger, etc.) on the clasp of your webpad ( WEB -INF / lib ).


Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -