spring 和 iBatis 集成 AnnotationMethodHandlerExceptionResolver$1
我是 spring 和 iBatis 的新手。我正在尝试集成两者,并且我已经放置了所有需要的 jar。但它仍然抛出以下异常。 我想我错过了一个相应的罐子。但我无法弄清楚。任何人都可以帮助我解决这个问题吗?
org.springframework.web.util.NestedServletException: Handler processing failed; nested exception is java.lang.NoClassDefFoundError: org/springframework/web/servlet/mvc/annotation/AnnotationMethodHandlerExceptionResolver$1
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:839)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
root cause
java.lang.NoClassDefFoundError: org/springframework/web/servlet/mvc/annotation/AnnotationMethodHandlerExceptionResolver$1
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.findBestExceptionHandlerMethod(AnnotationMethodHandlerExceptionResolver.java:176)
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.doResolveException(AnnotationMethodHandlerExceptionResolver.java:131)
org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver.resolveException(AbstractHandlerExceptionResolver.java:136)
org.springframework.web.servlet.DispatcherServlet.processHandlerException(DispatcherServlet.java:987)
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:811)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
root cause
java.lang.ClassNotFoundException: org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver$1
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1387)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.findBestExceptionHandlerMethod(AnnotationMethodHandlerExceptionResolver.java:176)
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.doResolveException(AnnotationMethodHandlerExceptionResolver.java:131)
org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver.resolveException(AbstractHandlerExceptionResolver.java:136)
org.springframework.web.servlet.DispatcherServlet.processHandlerException(DispatcherServlet.java:987)
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:811)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
提前致谢。 贾纳尔丹。
I am new to spring and iBatis.I am trying to integrate both and i have placed all the needed jars.But still it is throwing the following exception.
I think i miised a corresponding jar.But i am unable to figure it.Can any one please help me regarding this.
org.springframework.web.util.NestedServletException: Handler processing failed; nested exception is java.lang.NoClassDefFoundError: org/springframework/web/servlet/mvc/annotation/AnnotationMethodHandlerExceptionResolver$1
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:839)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
root cause
java.lang.NoClassDefFoundError: org/springframework/web/servlet/mvc/annotation/AnnotationMethodHandlerExceptionResolver$1
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.findBestExceptionHandlerMethod(AnnotationMethodHandlerExceptionResolver.java:176)
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.doResolveException(AnnotationMethodHandlerExceptionResolver.java:131)
org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver.resolveException(AbstractHandlerExceptionResolver.java:136)
org.springframework.web.servlet.DispatcherServlet.processHandlerException(DispatcherServlet.java:987)
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:811)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
root cause
java.lang.ClassNotFoundException: org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver$1
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1387)
org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.findBestExceptionHandlerMethod(AnnotationMethodHandlerExceptionResolver.java:176)
org.springframework.web.servlet.mvc.annotation.AnnotationMethodHandlerExceptionResolver.doResolveException(AnnotationMethodHandlerExceptionResolver.java:131)
org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver.resolveException(AbstractHandlerExceptionResolver.java:136)
org.springframework.web.servlet.DispatcherServlet.processHandlerException(DispatcherServlet.java:987)
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:811)
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:719)
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:644)
org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet.java:549)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
Thanks in advance.
Janardhan.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我假设您使用的是 spring-3.0 (因为旧版本中不存在此类),因此缺少的类位于
spring-webmvc-3.xxjar
中,例如:http://repo1.maven.org/maven2/org/springframework/spring- webmvc/3.0.5.RELEASE/
I assume you are using spring-3.0 (as this class doesn't exist in older versions), so the missing class is in
spring-webmvc-3.x.x.jar
, e.g.:http://repo1.maven.org/maven2/org/springframework/spring-webmvc/3.0.5.RELEASE/