0 Replies - 530 Views - Last Post: 20 September 2017 - 06:28 AM

#1 gssb45  Icon User is offline

  • New D.I.C Head

Reputation: -1
  • View blog
  • Posts: 9
  • Joined: 04-September 17

using springMVC framework..

Posted 20 September 2017 - 06:28 AM

I am trying to create simple project using SpringMVC framework.And getting error :
java.lang.ClassNotFoundException: org.springframework.beans.factory.config.BeanExpressionResolver

web.xml is like this :
<servlet>
      <servlet-name>HelloWeb</servlet-name>
      <servlet-class>
         org.springframework.web.servlet.DispatcherServlet
      </servlet-class>
      <load-on-startup>1</load-on-startup>
   </servlet>

   <servlet-mapping>
      <servlet-name>HelloWeb</servlet-name>
      <url-pattern>/</url-pattern>
   </servlet-mapping>


And HelloWeb-servlet.xml is like this:
   <beans><bean class = "org.springframework.web.servlet.view.InternalResourceViewResolver">
      <property name = "prefix" value = "/WEB-INF/jsp/" />
      <property name = "suffix" value = ".jsp" />
   </bean></beans>



And printing stackTrace is :
  java.lang.ClassNotFoundException: org.springframework.beans.factory.config.BeanExpressionResolver
	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1484)
	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1329)
	at java.lang.Class.getDeclaredConstructors0(Native Method)
	at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
	at java.lang.Class.getConstructor0(Unknown Source)
	at java.lang.Class.getDeclaredConstructor(Unknown Source)
	at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:78)
	at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:413)
	at org.springframework.web.servlet.FrameworkServlet.createWebApplicationContext(FrameworkServlet.java:458)
	at org.springframework.web.servlet.FrameworkServlet.initWebApplicationContext(FrameworkServlet.java:339)
	at org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:306)
	at org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:127)
	at javax.servlet.GenericServlet.init(GenericServlet.java:212)
	at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1173)
	at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:809)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:129)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:852)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
	at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
	at java.lang.Thread.run(Unknown Source)





Is This A Good Question/Topic? 0
  • +

Page 1 of 1