我在spring2.56时用到了spring中的context标签
<context:annotation-config/> 时,发现报如下错误:
问题描述:
org.springframework.beans.factory.parsing.BeanDefinitionParsingException: Configuration problem:
Unable to locate Spring NamespaceHandler for XML schema namespac[http://www.springframework.org/schema/context]
解决方案:
这个应该是jar和spring的配置文件中的声明不匹配导致的。
xmlns:context=http://www.springframework.org/schema/context
找到spring-context.jar包,
双击打开查看是否有
spring.handlers和spring.schemas文件。
如果有代表此spring-context.jar包是2.56版本,如果没有这两个文件则是spring2.0版本。
还有一种方式是查看MANIFEST.MF文件打开,查看spring-version是否是2.56以上的版本。
如果低于2.56则会报此异常,原因是spring2.0版本没有提供context的配置。
如果需要使用到context注解 则需要导入spring-context.jar 是2.56版本即可。
相关推荐
org.springframework.beans-3.0.4.RELEASE.jar org.springframework.context.support-3.0.4.RELEASE.jar org.springframework.context-3.0.4.RELEASE.jar org.springframework.core-3.0.4.RELEASE.jar org....
org.springframework.flex-1.0.3.RELEASE.jar.zip用于JAR包,org.springframework.flex-1.0.3.RELEASE.jar.zip用于JAR包org.springframework.flex-1.0.3.RELEASE.jar.zip用于JAR包org.springframework.flex-1.0.3....
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.transaction.interceptor.TransactionInterceptor#0': Error setting property values; nested ...
nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userController' defined in ServletContext resource [/WEB-INF/springMVC-servlet.xml]: Error ...
aopalliance-1.0.jar,org.springframework.aop-3.0.0.RELEASE.jar,org.springframework.jdbc-3.0.0.RELEASEorg.springframework.beans-3.0.0.RELEASE.jar等
Maven坐标:org.springframework:spring-beans:5.2.0.RELEASE; 标签:springframework、spring、beans、中英对照文档、jar包、java; 使用方法:解压翻译后的API文档,用浏览器打开“index.html”文件,即可纵览...
Maven坐标:org.springframework:spring-beans:5.0.10.RELEASE; 标签:spring、beans、springframework、jar包、java、API文档、中文版; 使用方法:解压翻译后的API文档,用浏览器打开“index.html”文件,即可...
org.springframework.beans-3.0.0.M4.jar
org.springframework.beans-sources-3.0.5.release.jar
org.springframework.beans-3.1.RELEASE.jar org.springframework.context.support-3.1.RELEASE.jar org.springframework.context-3.1.RELEASE.jar org.springframework.core-3.1.RELEASE.jar org.spring...
org.springframework.beans-3.0.5工程所需jar包,com.springsource.net.sf.cglib-2.2.0.jar、 com.springsource.org.apache.commons.logging-1.1.1.jar、 javax.inject.jar、 javax.servlet.jsp.jar、 org.spring...
org.springframework.beans-3.0.0.RELEASE.jar org.springframework.context.support-3.0.0.RELEASE.jar org.springframework.context-3.0.0.RELEASE.jar org.springframework.core-3.0.0.RELEASE.jar org.spring...
org.springframework.beans-3.1.0.M2
org.springframework.beans.factory.config org.springframework.beans.factory.parsing org.springframework.beans.factory.serviceloader org.springframework.beans.factory.support org.springframework.beans....
NULL 博文链接:https://chyy001.iteye.com/blog/1338488
org.springframework.beans-3.0.0.RELEASE org.springframework.context.support-3.0.0.RELEASE org.springframework.context-3.0.0.RELEASE org.springframework.core-3.0.0.RELEASE org.springframework....
org.springframework.beans-3.0.0.M3.jar
org.springframework.beans-3.1.0.RELEASE.jar
org.springframework.beans-2.5.5.A.jar, org.springframework.beans-2.5.6.A.jar, org.springframework.beans-2.5.6.SEC01.jar, org.springframework.beans-3.0.0.M1.jar, ...org.springframework.beans.jar
org.springframework.beans-3.0.5.RELEASE.jar org.springframework.context-3.0.5.RELEASE.jar org.springframework.context.support-3.0.5.RELEASE.jar org.springframework.core-3.0.5.RELEASE.jar org.spring...