org.apache.catalina.LifecycleException: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'guestController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private guest.GuestDao guest.GuestController.guestDao; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'guestDao': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/context/applicationContext-persistence.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: persistenceUnit] Unable to build EntityManagerFactory

Coderanch | sam White | 6 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    war file failed to deploy (Object Relational Mapping forum at Coderanch)

    coderanch.com | 11 months ago
    org.apache.catalina.LifecycleException: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'guestController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private guest.GuestDao guest.GuestController.guestDao; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'guestDao': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/context/applicationContext-persistence.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: persistenceUnit] Unable to build EntityManagerFactory
  2. 0

    war file failed to deploy

    Coderanch | 6 years ago | sam White
    org.apache.catalina.LifecycleException: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'guestController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private guest.GuestDao guest.GuestController.guestDao; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'guestDao': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/context/applicationContext-persistence.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: persistenceUnit] Unable to build EntityManagerFactory
  3. 0

    using "IN" Operator in hibernate

    Stack Overflow | 1 year ago | Billydan
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'agenceService': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private dz.com.naftal.referentiel.dao.AgenceDAO dz.com.naftal.referentiel.service.impl.AgenceServiceImpl.agenceDAO; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'agenceDAO': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'Oracle_driver' defined in class path resource [referentiel-dao-context.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: Oracle_driver] Unable to build EntityManagerFactory
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    NetBeans Forums - why Unable to build EntityManagerFactory?

    netbeans.org | 11 months ago
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customerServiceBean': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: SJTestPU] Unable to build EntityManagerFactory
  6. 0

    NetBeans Forums - why Unable to build EntityManagerFactory?

    netbeans.org | 2 years ago
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'customerServiceBean': Injection of persistence dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'entityManagerFactory' defined in ServletContext resource [/WEB-INF/applicationContext.xml]: Invocation of init method failed; nested exception is javax.persistence.PersistenceException: [PersistenceUnit: SJTestPU] Unable to build EntityManagerFactory

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. org.hibernate.HibernateException

      Errors in named queries: Guest.findBySingingdate

      at org.hibernate.impl.SessionFactoryImpl.<init>()
    2. Hibernate
      SessionFactoryImpl.<init>
      1. org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:365)
      1 frame
    3. Hibernate
      AnnotationConfiguration.buildSessionFactory
      1. org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1300)
      2. org.hibernate.cfg.AnnotationConfiguration.buildSessionFactory(AnnotationConfiguration.java:859)
      2 frames
    4. Hibernate EJB
      HibernatePersistence.createContainerEntityManagerFactory
      1. org.hibernate.ejb.Ejb3Configuration.buildEntityManagerFactory(Ejb3Configuration.java:669)
      2. org.hibernate.ejb.HibernatePersistence.createContainerEntityManagerFactory(HibernatePersistence.java:132)
      2 frames
    5. Spring ORM
      AbstractEntityManagerFactoryBean.afterPropertiesSet
      1. org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:225)
      2. org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:308)
      2 frames
    6. Spring Beans
      AbstractBeanFactory.getBean
      1. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1469)
      2. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1409)
      3. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)
      4. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
      5. org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
      6. org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
      7. org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
      8. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
      8 frames
    7. Spring ORM
      PersistenceAnnotationBeanPostProcessor$PersistenceElement.getResourceToInject
      1. org.springframework.orm.jpa.EntityManagerFactoryUtils.findEntityManagerFactory(EntityManagerFactoryUtils.java:99)
      2. org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.findNamedEntityManagerFactory(PersistenceAnnotationBeanPostProcessor.java:510)
      3. org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.findEntityManagerFactory(PersistenceAnnotationBeanPostProcessor.java:492)
      4. org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor$PersistenceElement.resolveEntityManager(PersistenceAnnotationBeanPostProcessor.java:656)
      5. org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor$PersistenceElement.getResourceToInject(PersistenceAnnotationBeanPostProcessor.java:629)
      5 frames
    8. Spring Beans
      InjectionMetadata.inject
      1. org.springframework.beans.factory.annotation.InjectionMetadata$InjectedElement.inject(InjectionMetadata.java:147)
      2. org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:84)
      2 frames
    9. Spring ORM
      PersistenceAnnotationBeanPostProcessor.postProcessPropertyValues
      1. org.springframework.orm.jpa.support.PersistenceAnnotationBeanPostProcessor.postProcessPropertyValues(PersistenceAnnotationBeanPostProcessor.java:338)
      1 frame
    10. Spring Beans
      DefaultListableBeanFactory.preInstantiateSingletons
      1. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1064)
      2. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:517)
      3. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
      4. org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
      5. org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
      6. org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
      7. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
      8. org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:827)
      9. org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:769)
      10. org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:686)
      11. org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:478)
      12. org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:84)
      13. org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:283)
      14. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1064)
      15. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:517)
      16. org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)
      17. org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:291)
      18. org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)
      19. org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:288)
      20. org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:190)
      21. org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:563)
      21 frames
    11. Spring Context
      AbstractApplicationContext.refresh
      1. org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:872)
      2. org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:423)
      2 frames
    12. Spring
      ContextLoaderListener.contextInitialized
      1. org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:276)
      2. org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:197)
      3. org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:47)
      3 frames
    13. Glassfish Core
      StandardContext.contextListenerStart
      1. org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:4690)
      1 frame
    14. Glassfish
      WebModule.contextListenerStart
      1. com.sun.enterprise.web.WebModule.contextListenerStart(WebModule.java:534)
      1 frame
    15. Glassfish Core
      StandardContext.start
      1. org.apache.catalina.core.StandardContext.start(StandardContext.java:5305)
      1 frame
    16. Glassfish
      WebModule.start
      1. com.sun.enterprise.web.WebModule.start(WebModule.java:500)
      1 frame
    17. Glassfish Core
      StandardHost.addChild
      1. org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:917)
      2. org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:901)
      3. org.apache.catalina.core.StandardHost.addChild(StandardHost.java:755)
      3 frames
    18. Glassfish
      WebApplication.start
      1. com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1980)
      2. com.sun.enterprise.web.WebContainer.loadWebModule(WebContainer.java:1630)
      3. com.sun.enterprise.web.WebApplication.start(WebApplication.java:100)
      3 frames
    19. Private APIs of Glassfish
      ApplicationInfo.start
      1. org.glassfish.internal.data.EngineRef.start(EngineRef.java:130)
      2. org.glassfish.internal.data.ModuleInfo.start(ModuleInfo.java:269)
      3. org.glassfish.internal.data.ApplicationInfo.start(ApplicationInfo.java:286)
      3 frames
    20. Kernel Classes
      ApplicationLifecycle.deploy
      1. com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:461)
      2. com.sun.enterprise.v3.server.ApplicationLifecycle.deploy(ApplicationLifecycle.java:240)
      2 frames
    21. Embedded GlassFish Web
      DeployCommand.execute
      1. org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:370)
      1 frame
    22. Kernel Classes
      CommandRunnerImpl$ExecutionContext.execute
      1. com.sun.enterprise.v3.admin.CommandRunnerImpl$1.execute(CommandRunnerImpl.java:360)
      2. com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:370)
      3. com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1067)
      4. com.sun.enterprise.v3.admin.CommandRunnerImpl.access$1200(CommandRunnerImpl.java:96)
      5. com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1247)
      5 frames
    23. Embedded GlassFish Web
      AutoDeployService$1.run
      1. org.glassfish.deployment.autodeploy.AutoOperation.run(AutoOperation.java:145)
      2. org.glassfish.deployment.autodeploy.AutoDeployer.deploy(AutoDeployer.java:577)
      3. org.glassfish.deployment.autodeploy.AutoDeployer.deployAll(AutoDeployer.java:463)
      4. org.glassfish.deployment.autodeploy.AutoDeployer.run(AutoDeployer.java:395)
      5. org.glassfish.deployment.autodeploy.AutoDeployer.run(AutoDeployer.java:380)
      6. org.glassfish.deployment.autodeploy.AutoDeployService$1.run(AutoDeployService.java:213)
      6 frames
    24. Java RT
      TimerThread.run
      1. java.util.TimerThread.mainLoop(Timer.java:512)
      2. java.util.TimerThread.run(Timer.java:462)
      2 frames