SSM项目问题总结

1.导入一个新项目报错The import javax.servlet.http.HttpServletRequest cannot be resolved
https://blog.csdn.net/nokia_lc/article/details/52204766
2.
端午假期复现重写一遍,有点乱!!!!!!!!!!!!

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
org.springframework.beans.factory.BeanDefinitionStoreException: IOException parsing XML document from class path resource [spring-mvc.xml]; nested exception is java.net.ConnectException: Connection timed out: connect
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:415)
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:336)
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:304)
at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:188)
at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:224)
at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:195)
at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:125)
at org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:94)
at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:133)
at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:636)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:521)
at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:400)
at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:291)
at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:103)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4770)
at org.apache.catalina.co
总的来说就是spring-mvc.xml文件找不到。查了网上很多的资料,又说jar缺少的,有说路径配置不对的。。。都没有解决我的问题。
说一下我的项目情况,我用springMVC做了一个demo测试一点东西。该项目没有涉及到spring和mybatis。也就是说关于配置文件只需要做SpringMVC相关的和web.xml。如下项目结构,controller使用的注解开发。
SSM项目问题总结_第1张图片
先后测试了一天,都没有解决。最终发现问题处在这里:注释掉该处后,解决了。
SSM项目问题总结_第2张图片
3.接2,解决了启动tomcat就报错之后

你可能感兴趣的:(SSM项目问题总结)