博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
spring 配置文件 xsd 过高导致启动不起来
阅读量:6148 次
发布时间:2019-06-21

本文共 5439 字,大约阅读时间需要 18 分钟。

 

报错提示来说应该是没有<beans>这个节点导致

 

org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 9 in XML document from ServletContext resource [/WEB-INF/app_context/ac-redis.xml] is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 9; columnNumber: 132; cvc-elt.1: Cannot find the declaration of element 'beans'.	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:398)	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:335)	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:303)	at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:180)	at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:216)	at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:187)	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:129)	at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:540)	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:454)	at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:403)	at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:306)	at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:106)	at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4727)	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5189)	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419)	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409)	at java.util.concurrent.FutureTask.run(FutureTask.java:266)	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)	at java.lang.Thread.run(Thread.java:745)Caused by: org.xml.sax.SAXParseException; lineNumber: 9; columnNumber: 132; cvc-elt.1: Cannot find the declaration of element 'beans'.	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:203)	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:134)	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:396)	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:327)	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:284)	at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:1900)	at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startElement(XMLSchemaValidator.java:740)	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:374)	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl$NSContentDriver.scanRootElementHook(XMLNSDocumentScannerImpl.java:613)	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:3132)	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(XMLDocumentScannerImpl.java:852)	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:602)	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:112)	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:505)	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:841)	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:770)	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)	at com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:243)	at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:339)	at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:76)	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadDocument(XmlBeanDefinitionReader.java:428)	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:390)	... 22 more

 

 

原因  本地 

 修改为

 

具体原因不清

 

 网传 多了空格,我看了自己的配置文件,没有多空格

 

 

 

 

 

 

 

 

 

 

 

 

 

捐助开发者 

在兴趣的驱动下,写一个免费的东西,有欣喜,也还有汗水,希望你喜欢我的作品,同时也能支持一下。 当然,有钱捧个钱场(支持支付宝和微信 以及扣扣群),没钱捧个人场,谢谢各位。

 

 
 
 谢谢您的赞助,我会做的更好!

 

转载地址:http://eyqya.baihongyu.com/

你可能感兴趣的文章
如何开发主控台部件
查看>>
RHCSA认证培训+考试七天实录(七)
查看>>
mysql HA 负载均衡
查看>>
VRRP 虚拟路由冗余协议(华为)
查看>>
Timer 控件中的Elapsed事件与tick事件的区别
查看>>
cpp学习(一)环境搭建
查看>>
人人都可能是网红,看网红的几种变现模式
查看>>
思考:真正的分布式数据库是否让“数据湖”概念成为历史?
查看>>
server2016下搭建web服务器&三种虚拟主机实验
查看>>
PostgrepSQL(大象)的使用
查看>>
【读书笔记】浪潮之巅第二版-“水果”公司的复兴、计算机工业生态链的三大定律...
查看>>
sdp协议
查看>>
Oracle技术之深入Linux PAM 体系结构(二)
查看>>
拯救自己的wifi
查看>>
CC-Inline-Assembly-HOWTO
查看>>
我的友情链接
查看>>
信用卡的交易充正
查看>>
CDH使用之CM、CDH4、5卸载
查看>>
理解javascript 回调函数
查看>>
麦肯锡:中国拥有3亿社交媒体用户为全球之最
查看>>