Ver Mensaje Individual
  #1 (permalink)  
Antiguo 02/05/2013, 03:32
carsoma
 
Fecha de Ingreso: mayo-2012
Mensajes: 26
Antigüedad: 12 años, 6 meses
Puntos: 0
Sonrisa Error usando Spring, Maven e Hibernate

Traza:

Código PHP:
Error creating bean with name 'transactionManager' defined in file [C:UsersTecnico1Documentsworkspace-sts-3.2.0.RELEASE.metadata.pluginsorg.eclipse.wst.s erver.coretmp1wtpwebappsmarshallWEB-INFclassesMETA-INFspringapplicationContext.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'nested exception is org.springframework.beans.factory.BeanCreationExce ptionError creating bean with name 'entityManagerFactory' defined in file [C:UsersTecnico1Documentsworkspace-sts-3.2.0.RELEASE.metadata.pluginsorg.eclipse.wst.s erver.coretmp1wtpwebappsmarshallWEB-INFclassesMETA-INFspringapplicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaH abitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
at org
.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveReference(BeanDefinitio nValueResolver.java:328)
at org.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveValueIfNecessary(BeanDe finitionValueResolver.java:106)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.applyPropertyValues(Abs tractAutowireCapableBeanFactory.java:1360)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.populateBean(AbstractAu towireCapableBeanFactory.java:1118)
…………..
at org.apache.catalina.core.StandardContext.listenerS tart(StandardContext.java:4797)
at org.apache.catalina.core.StandardContext.startInte rnal(StandardContext.java:5291)
at org.apache.catalina.util.LifecycleBase.start(Lifec ycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChildcall(ContainerBase.java:1559)
…………..

Caused byorg.springframework.beans.factory.BeanCreationExce ptionError creating bean with name 'entityManagerFactory' defined in file [C:UsersTecnico1Documentsworkspace-sts-3.2.0.RELEASE.metadata.pluginsorg.eclipse.wst.s erver.coretmp1wtpwebappsmarshallWEB-INFclassesMETA-INFspringapplicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaH abitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
at org
.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.initializeBean(Abstract AutowireCapableBeanFactory.java:1455)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.doCreateBean(AbstractAu towireCapableBeanFactory.java:519)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:456)
at org.springframework.beans.factory.support.Abstract BeanFactory$1.getObject(AbstractBeanFactory.java:2 94)
... 
25 more
Caused by
org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaH abitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
at org
.hibernate.cfg.ToOneFkSecondPass.doSecondPass(T oOneFkSecondPass.java:107)
at org.hibernate.cfg.Configuration.processEndOfQueueConfiguration.java:1580)
at org.hibernate.cfg.Configuration.processFkSecondPas sInOrder(Configuration.java:1503)
at org.hibernate.cfg.Configuration.secondPassCompileConfiguration.java:1419)
at org.hibernate.cfg.Configuration.buildMappings(Conf iguration.java:1375)
at org.hibernate.ejb.Ejb3Configuration.buildMappingsEjb3Configuration.java:1519)
at org.hibernate.ejb.EventListenerConfigurator.config ure(EventListenerConfigurator.java:193)
at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3 Configuration.java:1100)
at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3 Configuration.java:689)
at org.hibernate.ejb.HibernatePersistence.createConta inerEntityManagerFactory(HibernatePersistence.java :73)
... 
32 more
02
-may-2013 9:36:54 org.apache.catalina.core.StandardContext listenerStart
GRAVE
Excepción enviando evento inicializado de contexto a instancia de escuchador de clase org.springframework.web.context.ContextLoaderListe ner
org
.springframework.beans.factory.BeanCreationExce ptionError creating bean with name 'transactionManager' defined in file [C:UsersTecnico1Documentsworkspace-sts-3.2.0.RELEASE.metadata.pluginsorg.eclipse.wst.s erver.coretmp1wtpwebappsmarshallWEB-INFclassesMETA-INFspringapplicationContext.xml]: Cannot resolve reference to bean 'entityManagerFactory' while setting bean property 'entityManagerFactory'nested exception is org.springframework.beans.factory.BeanCreationExce ptionError creating bean with name 'entityManagerFactory' defined in file [C:UsersTecnico1Documentsworkspace-sts-3.2.0.RELEASE.metadata.pluginsorg.eclipse.wst.s erver.coretmp1wtpwebappsmarshallWEB-INFclassesMETA-INFspringapplicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaH abitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
at org
.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveReference(BeanDefinitio nValueResolver.java:328)
at org.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveValueIfNecessary(BeanDe finitionValueResolver.java:106)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.applyPropertyValues(Abs tractAutowireCapableBeanFactory.java:1360)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.populateBean(AbstractAu towireCapableBeanFactory.java:1118)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.doCreateBean(AbstractAu towireCapableBeanFactory.java:517)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:456)
…………..
at org.apache.catalina.core.StandardContext.listenerS tart(StandardContext.java:4797)
at org.apache.catalina.core.StandardContext.startInte rnal(StandardContext.java:5291)
at org.apache.catalina.util.LifecycleBase.start(Lifec ycleBase.java:150)
at org.apache.catalina.core.ContainerBase$StartChildcall(ContainerBase.java:1559)
at org.apache.catalina.core.ContainerBase$StartChildcall(ContainerBase.java:1549)
at java.util.concurrent.FutureTask$Sync.innerRun(Futu reTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.jav a:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.run Task(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
Caused byorg.springframework.beans.factory.BeanCreationExce ptionError creating bean with name 'entityManagerFactory' defined in file [C:UsersTecnico1Documentsworkspace-sts-3.2.0.RELEASE.metadata.pluginsorg.eclipse.wst.s erver.coretmp1wtpwebappsmarshallWEB-INFclassesMETA-INFspringapplicationContext.xml]: Invocation of init method failednested exception is org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaH abitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
at org
.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.initializeBean(Abstract AutowireCapableBeanFactory.java:1455)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.doCreateBean(AbstractAu towireCapableBeanFactory.java:519)
at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.createBean(AbstractAuto wireCapableBeanFactory.java:456)
at org.springframework.beans.factory.support.Abstract BeanFactory$1.getObject(AbstractBeanFactory.java:2 94)
at org.springframework.beans.factory.support.DefaultS ingletonBeanRegistry.getSingleton(DefaultSingleton BeanRegistry.java:225)
... 
25 more
Caused by
org.hibernate.AnnotationException: @OneToOne or @ManyToOne on com.springsource.marshall.domain.DocumentoReservaH abitacion.reservaHabitacionId references an unknown entitycom.springsource.marshall.domain.ReservaHabitacion
at org
.hibernate.cfg.ToOneFkSecondPass.doSecondPass(T oOneFkSecondPass.java:107)
at org.hibernate.cfg.Configuration.processEndOfQueueConfiguration.java:1580)
at org.hibernate.cfg.Configuration.processFkSecondPas sInOrder(Configuration.java:1503)
at org.hibernate.cfg.Configuration.secondPassCompileConfiguration.java:1419)
at org.hibernate.cfg.Configuration.buildMappings(Conf iguration.java:1375)
at org.hibernate.ejb.Ejb3Configuration.buildMappingsEjb3Configuration.java:1519)
at org.hibernate.ejb.EventListenerConfigurator.config ure(EventListenerConfigurator.java:193)
at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3 Configuration.java:1100)
at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3 Configuration.java:689)
at org.hibernate.ejb.HibernatePersistence.createConta inerEntityManagerFactory(HibernatePersistence.java :73)
at org.springframework.orm.jpa.LocalContainerEntityMa nagerFactoryBean.createNativeEntityManagerFactoryLocalContainerEntityManagerFactoryBean.java:268)
... 
32 more 

Soy nuevo y no controlo mucho de frameworks, creo q podría ser a algún jar duplicado, alguien sabe como solucionarlo.

Gracias!!