Direct access to controller path Http://localhost:8080/index error:
HTTP Status 500-servlet.init () for Servlets Spring threw exceptiontype Exception reportmessage servlet.init () for servlet Spring threw exceptiondescription the server encountered an internal error that prevented it from fulfilling this request . Exceptionjavax.servlet.ServletException:Servlet.init () for servlet Spring threw exception Org.apache.catalina.authenticator.AuthenticatorBase.invoke (authenticatorbase.java:504) Org.apache.catalina.valves.ErrorReportValve.invoke (errorreportvalve.java:79) Org.apache.catalina.valves.AbstractAccessLogValve.invoke (abstractaccesslogvalve.java:620) Org.apache.catalina.connector.CoyoteAdapter.service (coyoteadapter.java:502) Org.apache.coyote.http11.AbstractHttp11Processor.process (abstracthttp11processor.java:1132) Org.apache.coyote.abstractprotocol$abstractconnectionhandler.process (abstractprotocol.java:684) Org.apache.tomcat.util.net.aprendpoint$socketprocessor.dorun (aprendpoint.java:2521) Org.apache.tomcat.util.net.AprEndpoint$SocketProcessor. Run (aprendpoint.java:2510) Java.util.concurrent.ThreadPoolExecutor.runWorker ( threadpoolexecutor.java:1145) Java.util.concurrent.threadpoolexecutor$worker.run (ThreadPoolExecutor.java:615) Org.apache.tomcat.util.threads.taskthread$wrappingrunnable.run (taskthread.java:61) Java.lang.Thread.run ( thread.java:745) root causeorg.springframework.beans.factory.BeanCreationException:Error creating bean with Name ' Mytestservice ': Instantiation of Bean failed; Nested exception is java.lang.NoClassDefFoundError:Could not initialize class Com.alibaba.dubbo.config.spring.ReferenceBean Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean ( abstractautowirecapablebeanfactory.java:1155) Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance ( abstractautowirecapablebeanfactory.java:1099) Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean (abstractautowirecapablebeanfactory.java:513) Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean ( abstractautowirecapablebeanfactory.java:483) org.springframework.beans.factory.support.abstractbeanfactory$1. GetObject (abstractbeanfactory.java:306) Org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton ( defaultsingletonbeanregistry.java:230) Org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean ( abstractbeanfactory.java:302) Org.springframework.beans.factory.support.AbstractBeanFactory.getBean ( abstractbeanfactory.java:197) Org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons ( defaultlistablebeanfactory.java:742) Org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization ( abstractapplicationcontext.java:866) Org.springframework.context.support.AbstractApplicationContext.refresh ( abstractapplicationcontext.java:542) org.springFramework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext (frameworkservlet.java:668) Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext (frameworkservlet.java:634) Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext (frameworkservlet.java:682) Org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext (frameworkservlet.java:553) Org.springframework.web.servlet.FrameworkServlet.initServletBean (frameworkservlet.java:494) Org.springframework.web.servlet.HttpServletBean.init (httpservletbean.java:136) Javax.servlet.GenericServlet.init (genericservlet.java:158) Org.apache.catalina.authenticator.AuthenticatorBase.invoke (authenticatorbase.java:504) Org.apache.catalina.valves.ErrorReportValve.invoke (errorreportvalve.java:79) Org.apache.catalina.valves.AbstractAccessLogValve.invoke (abstractaccesslogvalve.java:620) Org.apache.catalina.connector.CoyoteAdapter.service (Coyoteadapter.java:502) org.apache.coyote.http11.AbstractHttp11Processor.process (abstracthttp11processor.java:1132) Org.apache.coyote.abstractprotocol$abstractconnectionhandler.process (abstractprotocol.java:684) Org.apache.tomcat.util.net.aprendpoint$socketprocessor.dorun (aprendpoint.java:2521) Org.apache.tomcat.util.net.aprendpoint$socketprocessor.run (aprendpoint.java:2510) Java.util.concurrent.ThreadPoolExecutor.runWorker (threadpoolexecutor.java:1145) Java.util.concurrent.threadpoolexecutor$worker.run (threadpoolexecutor.java:615) Org.apache.tomcat.util.threads.taskthread$wrappingrunnable.run (taskthread.java:61) Java.lang.Thread.run ( thread.java:745)
It was found that the JDK version of the Tomcat configuration is not correct, the original is JDK7 changed to JDK8 can be correctly accessed.
Project Access Controller error: HTTP Status 500-servlet.init () for Servlet Spring threw exception