Hi Friends -
I am using AnnotationSessionFactoryBean to configure the sessionFactory.
When I get the session factory and call createDatabaseSchema() method I am getting the follwoing exception:
[java] java.lang.NoClassDefFoundError: javax/persistence/InheritanceJoinColumns
[java] at org.hibernate.cfg.AnnotationBinder.bindClass(AnnotationBinder.java:324)
[java] at org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(AnnotationConfiguration.java:177)
[java] at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:999)
[java] at org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:769)
[java] at org.springframework.orm.hibernate3.LocalSessionFactoryBean.afterPropertiesSet(LocalSessionFactoryBean.java:695)
[java] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:966)
[java] at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:358)
[java] at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:226)
[java] at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)
[java] at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:270)
[java] at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:312)
[java] at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:80)
[java] at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:65)
..................
I am using JDK1.5, Hibernate 3.1 beta with spring 1.2.2. I verified ejb3-persistence.jar, but could not find the class javax.persistence.InheritanceJoinColumns.
Please let me know if any one has any idea.
Reagrds,
Omkar
|