I am new to this forum. I am trying to make an application using spring 3.2.6 and tomcat 7.0. I have added all the necessary jars in the WEB-INF/lib folder. The DispatcherServlet and ContextLoaderListener is properly configured in the web.xml. The same application was working fine with spring 3.0.2 version. Now when I am trying to open the jsp page, it is giving me below error:
HTTP Status 500 - org/springframework/web/servlet/HttpServletBean : org/springframework/context/EnvironmentAware
type Exception report
message org/springframework/web/servlet/HttpServletBean : org/springframework/context/EnvironmentAware
description The server encountered an internal error that prevented it from fulfilling this request.
exception
java.lang.NoClassDefFoundError: org/springframework/web/servlet/HttpServletBean : org/springframework/context/EnvironmentAware java.lang.ClassLoader.defineClass1(Native Method) java.lang.ClassLoader.defineClassCond(ClassLoader.java:632) java.lang.ClassLoader.defineClass(ClassLoader.java:616) java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2895) org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1173) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1681) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559) java.lang.ClassLoader.defineClass1(Native Method) java.lang.ClassLoader.defineClassCond(ClassLoader.java:632) java.lang.ClassLoader.defineClass(ClassLoader.java:616) java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2895) org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1173) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1681) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559) java.lang.ClassLoader.defineClass1(Native Method) java.lang.ClassLoader.defineClassCond(ClassLoader.java:632) java.lang.ClassLoader.defineClass(ClassLoader.java:616) java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2895) org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1173) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1681) org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559) org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:491) org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99) org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:953) org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:408) org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1023) org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:589) org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312) java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) java.lang.Thread.run(Thread.java:662)
note The full stack trace of the root cause is available in the Apache Tomcat/7.0.42 logs.
The jar
spring-context-3.2.6.RELEASE
is already added in the classpath. I am able to open the class file also from the Eclipse. But I don't understand why it is giving class not found error at run time. I tried to search it on google but didn't find exact the solution. Thanks in advance.