问题描述
WebContext(/PMRS),ERROR:action:null+org.springframework.beans.factory.BeanCreationException:Errorcreatingbeanwithname'busExeProjectDAO'definedinfile[/web_data/pmrs.war/WEB-INF/classes/spring/businessdao.xml]:Can'tresolvereferencetobean'PagePmrClient'whilesettingproperty'sqlMapClient';nestedexceptionisorg.springframework.beans.factory.BeanCreationException:Errorcreatingbeanwithname'PagePmrClient'definedinfile[/web_data/pmrs.war/WEB-INF/classes/spring/database.xml]:Initializationofbeanfailed;nestedexceptionisjava.lang.RuntimeException:Erroroccurred.Cause:com.ibatis.common.xml.NodeletException:ErrorparsingXML.Cause:java.lang.RuntimeException:ErrorparsingXPath'/sqlMapConfig/sqlMap'.Cause:com.ibatis.common.xml.NodeletException:ErrorparsingXML.Cause:org.xml.sax.SAXParseException:AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocument.+org.springframework.beans.factory.BeanCreationException:Errorcreatingbeanwithname'PagePmrClient'definedinfile[/web_data/pmrs.war/WEB-INF/classes/spring/database.xml]:Initializationofbeanfailed;nestedexceptionisjava.lang.RuntimeException:Erroroccurred.Cause:com.ibatis.common.xml.NodeletException:ErrorparsingXML.Cause:java.lang.RuntimeException:ErrorparsingXPath'/sqlMapConfig/sqlMap'.Cause:com.ibatis.common.xml.NodeletException:ErrorparsingXML.Cause:org.xml.sax.SAXParseException:AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocument.+java.lang.RuntimeException:Erroroccurred.Cause:com.ibatis.common.xml.NodeletException:ErrorparsingXML.Cause:java.lang.RuntimeException:ErrorparsingXPath'/sqlMapConfig/sqlMap'.Cause:com.ibatis.common.xml.NodeletException:ErrorparsingXML.Cause:org.xml.sax.SAXParseException:AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocument.+atcom.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser.parse(SqlMapConfigParser.java:89)+atcom.ibatis.sqlmap.client.SqlMapClientBuilder.buildSqlMapClient(SqlMapClientBuilder.java:63)+atorg.springframework.orm.ibatis.SqlMapClientFactoryBean.afterPropertiesSet(SqlMapClientFactoryBean.java:258)+atcom.ibatis.sqlmap.client.spring.CustomSqlMapClientFactoryBean.afterPropertiesSet(CustomSqlMapClientFactoryBean.java:19)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1058)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:363)+atorg.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:226)+atorg.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)+atorg.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:176)+atorg.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:105)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1012)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:823)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:345)+atorg.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:239)+atorg.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:147)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByName(AbstractAutowireCapableBeanFactory.java:843)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:811)+atorg.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:345)+
解决方案
解决方案二:
ibatis是配置文件XML写错了么?
解决方案三:
引用1楼wobuxiangnila的回复:
ibatis是配置文件XML写错了么?
感觉没有啊,检查了好久没问题的
解决方案四:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的
解决方案五:
引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的
-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
解决方案六:
引用4楼w269237176wangtao的回复:
Quote: 引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
异常中说你有个非法的XML字符,这东西很难找
解决方案七:
引用5楼longtian1213的回复:
Quote: 引用4楼w269237176wangtao的回复:
Quote: 引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
异常中说你有个非法的XML字符,这东西很难找
有没可能是跟系统的字符编码不符合产生的哦。。。linux系统的。。系统的字符编码是utf_8但程序的是GBK
解决方案八:
引用5楼longtian1213的回复:
Quote: 引用4楼w269237176wangtao的回复:
Quote: 引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
异常中说你有个非法的XML字符,这东西很难找
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
解决方案九:
引用7楼w269237176wangtao的回复:
Quote: 引用5楼longtian1213的回复:
Quote: 引用4楼w269237176wangtao的回复:
Quote: 引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
异常中说你有个非法的XML字符,这东西很难找
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
解决方案十:
引用8楼w269237176wangtao的回复:
Quote: 引用7楼w269237176wangtao的回复:
Quote: 引用5楼longtian1213的回复:
Quote: 引用4楼w269237176wangtao的回复:
Quote: 引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
异常中说你有个非法的XML字符,这东西很难找
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
你最好能统一编码,可以少很多麻烦
解决方案十一:
引用9楼longtian1213的回复:
Quote: 引用8楼w269237176wangtao的回复:
Quote: 引用7楼w269237176wangtao的回复:
Quote: 引用5楼longtian1213的回复:
Quote: 引用4楼w269237176wangtao的回复:
Quote: 引用3楼longtian1213的回复:
AninvalidXMLcharacter(Unicode:0xd8e8)wasfoundintheelementcontentofthedocumen你的配置文件肯定有问题,还是个很难找的字符问题,你重建个吧,不要复制旧的-<resource-refid="ResourceRef_1"><res-ref-name>DocManage/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_2"><res-ref-name>PMRS3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_3"><res-ref-name>PMRS/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>-<resource-refid="ResourceRef_4"><res-ref-name>DocManage3195000003/DataSource</res-ref-name><res-type>javax.sql.DataSource</res-type><res-auth>Container</res-auth></resource-ref>只改动了这里请问有问题么
异常中说你有个非法的XML字符,这东西很难找
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
有没有可能是系统的字符编码不一样喃。linux系统是utf_8程序是gbk
你最好能统一编码,可以少很多麻烦
好的谢谢你