Tomcat容器启动失败,找到 debug日志一看:

 Context initialization failed

     org.springframework. beans.factory.xml.XmlBeanDefinitionStoreException:Line 1 in XML document from file [spring-wlf.xml] is invalid;nested exception is org.xml.sax.SAXParseException:The processing instruction target matching "[xX][mM][1L]” is not allowed.

  回头打开spring-wlf.xml仔细看了下

 <?xml version="1.0" encoding="UTF-8"?>

  竟然在文件开头多了一个空格,导致识别不了文件。不得不承认,有时候问题就是这么纠结而细微:在<?xml前面有个不起眼的空格。

相关文章:

  • 2021-11-18
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-12-05
  • 2022-12-23
  • 2021-06-03
  • 2021-10-17
猜你喜欢
  • 2022-12-23
  • 2021-10-23
  • 2021-07-24
  • 2022-12-23
  • 2021-09-30
  • 2021-08-05
  • 2021-06-09
相关资源
相似解决方案