Servlet [springDispatcherServlet] in web application [/SpringMVC-1] threw load() exception java.lang
来源:互联网 发布:php reflection 编辑:程序博客网 时间:2024/06/06 19:02
SpringMVC 启动时报 DispatcherServlet 找不到
严重: Servlet [springDispatcherServlet] in web application[/SpringMVC-1] threw load() exceptionjava.lang.ClassNotFoundException:org.springframework.web.servlet.DispatcherServlet
1、DispatcherServlet类在 spring-webmvcjar包下,先确定导入了该包。
2、还要把依赖都加进classpath下:项目右击-->properties-->DeploymentAssembly-->add-->Java Build PathEntries-->导入所有依赖的Jar包,重新start tomcat即可。
不知道依赖那些包,就把Java Build PathEntries 下面的包全部导入,只能一个一个的选;
这种问题对于我这种新手来说真是太费劲了。。。。
追加:
今天发现了更好的解决办法,原来是因为 Eclipse 不支持 WebContent/WEB-INF/lib下有分级目录,所有把所有 jar 包直接丢这个目录下就不会出现以上问题了,而且还能自动导入到项目。出现上面问题时我是手动 Add toBuild Path的;哇哇哇瞬间感觉坑到家了。。。。
--------------------------------------------转自小子万花筒的博客
-----------原文地址http://blog.sina.com.cn/s/blog_166b7cc410102xb41.html
- Servlet [springDispatcherServlet] in web application [/SpringMVC-1] threw load() exception java.lang
- 严重: Servlet [login_fali] in web application [/StudyforJSP] threw load() exception javax.servl
- Java Web Servlet.init() for servlet springMVC threw exception解决
- bug解决(SpringMVC)- 严重: Servlet /SpringMVC threw load() exception
- Servlet /shop threw load() exception,java.lang.NoClassDefFoundError: org/apache/jasper/logging/Logger
- 严重: Servlet /day18_3 threw load() exception java.lang.StringIndexOutOfBoundsException: String index
- Servlet.service() for servlet jsp threw exception java.lang.NullPointerException
- Servlet.service() for servlet jsp threw exception java.lang.NullPointerException
- Servlet.service() for servlet jsp threw exception java.lang.NullPointerException
- 严重: Servlet /NewsSystem_SSH threw load() exception
- 严重: Servlet /ziyuanbookProject threw load() exception
- Servlet.service() for servlet [springmvc] in context with path [] threw exception [Request processin
- Servlet.service() for servlet [springMVC] in context with path [] threw exception [Could not get Req
- Servlet.service() for servlet [springMVC] in context with path [/project_manager] threw exception [R
- Servlet.service() for servlet springmvc threw exception org.apache.jasper.JasperException: /WEB-INF/
- 严重: Servlet.service() for servlet default threw exception java.lang.OutOfMemoryError: Java heap spac
- 严重: Servlet.service() for servlet jsp threw exception java.lang.IllegalStateException: getOutputStream() has already been called
- 严重: Servlet.service() for servlet jsp threw exception java.lang.NoSuchMethodError: com.opensymphony.
- MenuItemSprite
- opencv 调节图片亮度和对比度(注意头文件顺序)
- Vue2.0生命周期和钩子函数的一些理解
- 哈希表的概念及作用
- Java——Character类
- Servlet [springDispatcherServlet] in web application [/SpringMVC-1] threw load() exception java.lang
- MenuItemImage
- IOS上传代码到GitHub步骤
- Node.js与PHP之间通过RSA算法实现签名验证
- ReactNative的介绍
- 本文实例讲述了js获取当前日期前七天的方法
- MenuItemFont、MenuItemLabel
- 心情小感悟
- MenuItemToggle