码迷,mamicode.com
首页 > 编程语言 > 详细

java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet

时间:2016-03-18 00:01:49      阅读:630      评论:0      收藏:0      [点我收藏+]

标签:

新建Maven 项目的时候报错:

java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet

java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1678)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1523)
    at org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:525)
    at org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:507)
    at org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:126)
    at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1099)
    at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1043)
    at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4957)
    at org.apache.catalina.core.StandardContext$3.call(StandardContext.java:5284)
    at org.apache.catalina.core.StandardContext$3.call(StandardContext.java:5279)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
    at java.lang.Thread.run(Thread.java:662)

You need to add the "Maven Dependency" in the Deployement Assembly

  • right click on your project and choose properties.
  • click on Deployement Assembly.
  • click add
  • click on "Java Build Path Entries"
  • select Maven Dependencies"
  • click Finish.

java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet

java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet

标签:

原文地址:http://www.cnblogs.com/vincent4code/p/5290067.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!