启动tomcat出错。。。ERROR [localhost-startStop-1] - Context initialization failed

 

原因:web.xml文件中没有加载spring 的一系列配置文件ApplicationContext-*.xml

解决:加载spring配置文件

  <context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>classpath:spring/ApplicationContext-*.xml</param-value>
  </context-param>
  <listener>
    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  </listener>

相关文章:

  • 2021-12-25
  • 2022-12-23
  • 2021-05-14
  • 2021-09-27
  • 2021-06-11
  • 2022-12-23
猜你喜欢
  • 2021-08-01
  • 2022-12-23
  • 2021-06-24
  • 2021-09-17
  • 2021-12-04
  • 2022-12-23
相关资源
相似解决方案