1, I used the eclipse4.5, created a good MAVEN managed Web project, found Java build path libraries missing Tomcat Lib, the following figure
2. Selected items – Right key properties –projects facets
Select the Web version, the Java version will ultimately be in the window to the right of the runtimes option to check the corresponding Tomcat version, I use here is tomcat8, finally remember to click the Apply button
3, the following figure, Tomcat Lib in the libraries inside the
If you do not have Tomcat Lib, you are likely to lack the following error for the Lib report in Tomcat
Serious: standardwrapper.throwable Java.lang.NoClassDefFoundError:HttpServletRequest at Java.lang.Class.getDeclaredMethods0 (Native method) at Java.lang.Class.privateGetDeclaredMethods (class.java:2701) A T Java.lang.Class.getDeclaredMethods (class.java:1975) at Org.springframework.util.ReflectionUtils.getDeclaredMethods (reflectionutils.java:571) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:488) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:501) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:474) at Org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors (autowiredannotationbeanpostprocessor.java:241) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsFromBeanPostProcessors (abstractautowirecapablebeanfactory.java:1065) at Org.springframework.beans.factoRy.support.AbstractAutowireCapableBeanFactory.createBeanInstance (abstractautowirecapablebeanfactory.java:1038) 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.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons ( defaultlistablebeanfactory.java:755) at Org.sPringframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization ( abstractapplicationcontext.java:757) at Org.springframework.context.support.AbstractApplicationContext.refresh ( abstractapplicationcontext.java:480) at Org.springframework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext ( frameworkservlet.java:663) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:629) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:677) at Org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext ( frameworkservlet.java:548) at Org.springframework.web.servlet.FrameworkServlet.initServletBean ( frameworkservlet.java:489) at Org.springframework.web.servlet.HttpServletBean.init (httpservletbean.java:136) at Ja Vax.servlet.GenericServlet.init (genericservlet.java:158) at Org.apache.catalina.core.StandardWrapper.initServlet (standardwrapper.java:1231) at Org.apache.catalina.core.StandardWrapper.loadServlet (Standardwrapper.java : 1144) at Org.apache.catalina.core.StandardWrapper.load (standardwrapper.java:1031) at Org.apache.catalina.core.Sta Ndardcontext.loadonstartup (standardcontext.java:4914) at Org.apache.catalina.core.StandardContext.startInternal ( standardcontext.java:5201) at Org.apache.catalina.util.LifecycleBase.start (lifecyclebase.java:150) at org.apache.c Atalina.core.containerbase$startchild.call (containerbase.java:1408) at org.apache.catalina.core.containerbase$ Startchild.call (containerbase.java:1398) at the Java.util.concurrent.FutureTask.run (futuretask.java:266) at Java.util. Concurrent. Threadpoolexecutor.runworker (threadpoolexecutor.java:1142) at Java.util.concurrent.threadpoolexecutor$worker.run (threadpoolexecutor.java:617) at Java.lang.Thread.run (thread.java:745) caused by:java.lang.ClassNotFoundException: HttpServletRequest at Org.apache.catalIna.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1332) at Org.apache.catalina.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1166) ... More February 22, 2016 8:55:50 pm org.apache.catalina.core.StandardContext loadonstartup severity: Servlet [SPRINGMVC] in Web APPL ication [/HGBJ] threw load () exception java.lang.ClassNotFoundException:HttpServletRequest at Org.apache.catalina.loa Der. Webappclassloaderbase.loadclass (webappclassloaderbase.java:1332) at Org.apache.catalina.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1166) at Java.lang.Class.getDeclaredMethods0 (Native method) at Java.lang.Class.privateGetDeclaredMethods (class.java:2701) A T Java.lang.Class.getDeclaredMethods (class.java:1975) at Org.springframework.util.ReflectionUtils.getDeclaredMethods (reflectionutils.java:571) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:488) at Org.springframework.util.ReflectioNutils.dowithmethods (reflectionutils.java:501) at Org.springframework.util.ReflectionUtils.doWithMethods ( reflectionutils.java:474) at Org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors (autowiredannotationbeanpostprocessor.java:241) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsFromBeanPostProcessors (abstractautowirecapablebeanfactory.java:1065) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance ( abstractautowirecapablebeanfactory.java:1038) 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.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons ( defaultlistablebeanfactory.java:755) at Org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization ( abstractapplicationcontext.java:757) at Org.springframework.context.support.AbstractApplicationContext.refresh ( abstractapplicationcontext.java:480) at Org.springframework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext ( frameworkservlet.java:663) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:629) at orG.springframework.web.servlet.frameworkservlet.createwebapplicationcontext (frameworkservlet.java:677) at Org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext (frameworkservlet.java:548) at Org.springframework.web.servlet.FrameworkServlet.initServletBean (frameworkservlet.java:489) at Org.springframework.web.servlet.HttpServletBean.init (httpservletbean.java:136) at Javax.servlet.GenericServlet.init (genericservlet.java:158) at Org.apache.catalina.core.StandardWrapper.initServlet (standardwrapper.java:1231) at Org.apache.catalina.core.StandardWrapper.loadServlet (standardwrapper.java:1144) at Org.apache.catalina.core.StandardWrapper.load (standardwrapper.java:1031) at Org.apache.catalina.core.StandardContext.loadOnStartup (standardcontext.java:4914) at Org.apache.catalina.core.StandardContext.startInternal (standardcontext.java:5201) at Org.apache.catalina.util.LifecycleBase.start (lifecyclebase.java:150) at Org.apache.catalina.corE.containerbase$startchild.call (containerbase.java:1408) at org.apache.catalina.core.containerbase$ Startchild.call (containerbase.java:1398) at the Java.util.concurrent.FutureTask.run (futuretask.java:266) at Java.util. Concurrent. Threadpoolexecutor.runworker (threadpoolexecutor.java:1142) at Java.util.concurrent.threadpoolexecutor$worker.run (threadpoolexecutor.java:617) at Java.lang.Thread.run (thread.java:745) February 22, 2016 8:55:50 pm ORG.APACHE.COYOTE.ABSTR Actprotocol Start Info: Starting Protocolhandler ["http-nio-8080"] Hile 22, 2016 8:55:50 pm Org.apache.coyote.AbstractProtoco L Start Info: Starting Protocolhandler ["ajp-nio-8009"] Hile 22, 2016 8:55:50 pm Org.apache.catalina.startup.Catalina start Info : Server Startup in 3600 Ms February 22, 2016 8:55:51 pm org.apache.catalina.core.ApplicationContext log information: initializing Spring Frameworkservlet ' Springmvc ' Hile 22, 2016 8:55:51 p.m. Org.apache.catalina.core.ApplicationContext log Serious: Standardwrapper. Throwable Java.lang.NoClassDefFoundError: HttpServletRequest at Java.lang.Class.getDeclaredMethods0 (Native method) at Java.lang.Class.privateGetDeclaredMe Thods (class.java:2701) at Java.lang.Class.getDeclaredMethods (class.java:1975) at Org.springframework.util.Reflecti Onutils.getdeclaredmethods (reflectionutils.java:571) at Org.springframework.util.ReflectionUtils.doWithMethods ( reflectionutils.java:488) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:501) at O Rg.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:474) at Org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors (autowiredannotationbeanpostprocessor.java:241) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsFromBeanPostProcessors (abstractautowirecapablebeanfactory.java:1065) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstAnce (abstractautowirecapablebeanfactory.java:1038) 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.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons ( defaultlistablebeanfactory.java:755) at org.springframework.context.support.AbstractApplicationContext.fiNishbeanfactoryinitialization (abstractapplicationcontext.java:757) at Org.springframework.context.support.AbstractApplicationContext.refresh (abstractapplicationcontext.java:480) at Org.springframework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext ( frameworkservlet.java:663) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:629) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:677) at Org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext ( frameworkservlet.java:548) at Org.springframework.web.servlet.FrameworkServlet.initServletBean ( frameworkservlet.java:489) at Org.springframework.web.servlet.HttpServletBean.init (httpservletbean.java:136) at Ja Vax.servlet.GenericServlet.init (genericservlet.java:158) at Org.apache.catalina.core.StandardWrapper.initServlet (standardwrapper.java:1231) at Org.apache.catalinA.core.standardwrapper.loadservlet (standardwrapper.java:1144) at Org.apache.catalina.core.StandardWrapper.allocate (standardwrapper.java:817) at Org.apache.catalina.core.StandardWrapperValve.invoke (standardwrappervalve.java:135) at Org.apache.catalina.core.StandardContextValve.invoke (standardcontextvalve.java:106) at Org.apache.catalina.authenticator.AuthenticatorBase.invoke (authenticatorbase.java:502) 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:616) at Org.apache.catalina.core.StandardEngineValve.invoke (standardenginevalve.java:88) at Org.apache.catalina.connector.CoyoteAdapter.service (coyoteadapter.java:518) at Org.apache.coyote.http11.AbstractHttp11Processor.process (abstracthttp11processor.java:1091) at org.apache.coyote.abstractprotocol$aBstractconnectionhandler.process (abstractprotocol.java:673) at org.apache.tomcat.util.net.nioendpoint$ Socketprocessor.dorun (nioendpoint.java:1526) at Org.apache.tomcat.util.net.nioendpoint$socketprocessor.run ( nioendpoint.java:1482) 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:745) caused by:java.lang.ClassNotFoundException:HttpServletRequest at Org.apache.catalina.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1332) at Org.apache.catalina.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1166) ... February 22, 2016 8:55:51 pm org.apache.catalina.core.StandardWrapperValve invoke severity: Allocate exception for servlet sp Ringmvc java.lang.ClassNotFoundException:HttpServletRequesT at Org.apache.catalina.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1332) at Org.apache.cat Alina.loader.WebappClassLoaderBase.loadClass (webappclassloaderbase.java:1166) at Java.lang.Class.getDeclaredMethods0 (Native method) at Java.lang.Class.privateGetDeclaredMethods (class.java:2701) A T Java.lang.Class.getDeclaredMethods (class.java:1975) at Org.springframework.util.ReflectionUtils.getDeclaredMethods (reflectionutils.java:571) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:488) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:501) at Org.springframework.util.ReflectionUtils.doWithMethods (reflectionutils.java:474) at Org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.determineCandidateConstructors (autowiredannotationbeanpostprocessor.java:241) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineConstructorsfrombeanpostprocessors (abstractautowirecapablebeanfactory.java:1065) at Org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance ( abstractautowirecapablebeanfactory.java:1038) 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.beanS.factory.support.defaultlistablebeanfactory.preinstantiatesingletons (defaultlistablebeanfactory.java:755) at Org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization ( abstractapplicationcontext.java:757) at Org.springframework.context.support.AbstractApplicationContext.refresh ( abstractapplicationcontext.java:480) at Org.springframework.web.servlet.FrameworkServlet.configureAndRefreshWebApplicationContext ( frameworkservlet.java:663) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:629) at Org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext ( frameworkservlet.java:677) at Org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext ( frameworkservlet.java:548) at Org.springframework.web.servlet.FrameworkServlet.initServletBean ( frameworkservlet.java:489) at Org.springframework.web.servlet.HttpServletBean.init (httpservletbean.java:136)
At Javax.servlet.GenericServlet.init (genericservlet.java:158) at Org.apache.catalina.core.StandardWrapper.initSer Vlet (standardwrapper.java:1231) at Org.apache.catalina.core.StandardWrapper.loadServlet (Standardwrapper.java : 1144) at Org.apache.catalina.core.StandardWrapper.allocate (standardwrapper.java:817) at Org.apache.catalina.core. Standardwrappervalve.invoke (standardwrappervalve.java:135) at Org.apache.catalina.core.StandardContextValve.invoke (standardcontextvalve.java:106) at Org.apache.catalina.authenticator.AuthenticatorBase.invoke (authenticatorbase.java:502) 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:616) at Org.apache.catalina.core.StandardEngineValve.invoke (standardenginevalve.java:88) at Org.apache.catalina.connector.CoyoteAdaPter.service (coyoteadapter.java:518) at Org.apache.coyote.http11.AbstractHttp11Processor.process ( abstracthttp11processor.java:1091) at Org.apache.coyote.abstractprotocol$abstractconnectionhandler.process (
abstractprotocol.java:673)