异常:spring
org.xml.sax.SAXParseException; lineNumber: 78; columnNumber: 69; schema_reference.4: 没法读取方案文档 'http://www.springframework.org/schema/tx/spring-tx-3.2.xsd', 缘由为 1) 没法找到文档; 2) 没法读取文档; 3) 文档的根元素不是 <xsd:schema>。.net
Line 78 in XML document from class path resource [biz-context.xml] is invalid; nested exception is org.xml.sax.SAXParseException; lineNumber: 78; columnNumber: 69; cvc-complex-type.2.4.c: 通配符的匹配很全面, 但没法找到元素 'tx:annotation-driven' 的声明。xml
缘由是由于blog
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx" xmlns:jdbc="http://www.springframework.org/schema/jdbc"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:task="http://www.springframework.org/schema/task"
xsi:schemaLocation="
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.2.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.2.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.2.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.2.xsd
http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task-3.2.xsd">文档
在链接外网正常状况下 经过 xmlns="http://www.springframework.org/schema/beans 连接能够远程获取spring-task-3.2.xsd 配置文件信息,可是当远程连接出现异常时就会经过xsi:schemaLocation加载本地项目工程spring-tx-3.2.6.RELEASE.jar包中的spring.schemas文件中路径获取spring-task-3.2.xsd 配置文件(http\://www.springframework.org/schema/tx/spring-tx.xsd=org/springframework/transaction/config/spring-tx-3.0.xsd),全部若是spring-tx-3.2.6.RELEASE.jar包中的spring.schemas文件没有http\://www.springframework.org/schema/tx/spring-tx.xsd=org/springframework/transaction/config/spring-tx-3.2.xsd路径,则下载更高级版本的包或低版本的jar包,而且查看是否有http\://www.springframework.org/schema/tx/spring-tx.xsd=org/springframework/transaction/config/spring-tx-3.2.xsd配置路径。io
资料路径:class
https://blog.csdn.net/dingqinghu/article/details/46758671配置