Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via Spring JIRA by Tyron James Hall, 1 year ago
Error creating bean with name 'entityManagerFactory' defined in com.tyron.config.AppConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean]: Factory method 'entityManagerFactory' threw exception; nested exception is java.lang.NullPointerException
via Spring JIRA by Tyron James Hall, 2 years ago
Error creating bean with name 'entityManagerFactory' defined in com.tyron.config.AppConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean]: Factory method 'entityManagerFactory' threw exception; nested exception is java.lang.NullPointerException
via GitHub by Timple
, 11 months ago
Error creating bean with name 'entityManagerFactory' defined in com.github.swrirobotics.config.JpaConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate
via Stack Overflow by Ondrej Tokar
, 2 years ago
Error creating bean with name 'entityManagerFactory' defined in org.maguss.config.AppConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate
via Stack Overflow by javatechnology
, 1 year ago
Error creating bean with name 'entityManagerFactory' defined in org.baeldung.config.PersistenceJNDIConfig: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate
via sivalabs.in by Unknown author, 2 years ago
Error creating bean with nameentityManagerFactorydefined in class path resource [com/sivalabs/springapp/config/PersistenceConfig.class]: Instantiation of bean failed; nested exception is
java.lang.NullPointerException: 	at com.tyron.config.AppConfig.entityManagerFactory(AppConfig.java:87)	at com.tyron.config.AppConfig$$EnhancerBySpringCGLIB$$60f3127f.CGLIB$entityManagerFactory$1()	at com.tyron.config.AppConfig$$EnhancerBySpringCGLIB$$60f3127f$$FastClassBySpringCGLIB$$c78012aa.invoke()	at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)	at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:309)	at com.tyron.config.AppConfig$$EnhancerBySpringCGLIB$$60f3127f.entityManagerFactory()	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)	at java.lang.reflect.Method.invoke(Method.java:483)	at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162)	at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:588)	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1111)	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1006)	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:504)	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:476)	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:303)	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230)	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:299)	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:194)	at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:956)	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:747)	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:480)	at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:403)	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306)	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106)	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4795)	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5221)	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724)	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:714)	at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:581)	at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:455)	at org.apache.catalina.startup.HostConfig.check(HostConfig.java:1495)	at sun.reflect.GeneratedMethodAccessor84.invoke(Unknown Source)	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)	at java.lang.reflect.Method.invoke(Method.java:483)	at org.apache.tomcat.util.modeler.BaseModelMBean.invoke(BaseModelMBean.java:300)	at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:819)	at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:801)	at org.apache.catalina.manager.ManagerServlet.check(ManagerServlet.java:1432)	at org.apache.catalina.manager.ManagerServlet.deploy(ManagerServlet.java:884)	at org.apache.catalina.manager.ManagerServlet.doGet(ManagerServlet.java:335)	at javax.servlet.http.HttpServlet.service(HttpServlet.java:618)	at javax.servlet.http.HttpServlet.service(HttpServlet.java:725)	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)	at org.apache.catalina.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:108)	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219)	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106)	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:618)	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:142)	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)	at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610)	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:537)	at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1081)	at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:658)	at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:277)	at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.doRun(AprEndpoint.java:2403)	at org.apache.tomcat.util.net.AprEndpoint$SocketProcessor.run(AprEndpoint.java:2392)	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)	at java.lang.Thread.run(Thread.java:744)