解决eclipse spring-MVC配置报错:cvc-elt.1: Cannot find the declaration of element 'beans'.
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd">
spring-MVC配置一直报错:cvc-elt.1: Cannot find the declaration of element 'beans'.
联网正常, http://www.springframework.org/schema/beans/spring-beans.xsd,浏览器可正常打开。
原因是无法从网络上读取到相应的schema文件,但实际上在浏览器中是可以访问的。
可以改成 xsi:schemaLocation="
http://www.springframework.org/schema/beans
classpath:/org/springframework/beans/factory/xml/spring-beans-2.5.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd">
从本地JAR包获取即可,无需从网上读取
AtomGit 是由开放原子开源基金会联合 CSDN 等生态伙伴共同推出的新一代开源与人工智能协作平台。平台坚持“开放、中立、公益”的理念,把代码托管、模型共享、数据集托管、智能体开发体验和算力服务整合在一起,为开发者提供从开发、训练到部署的一站式体验。
更多推荐


所有评论(0)