I have the following spring servlet-context.xml file:
<?xml version="1.0" encoding="UTF-8"?>
<beans
xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:sec="http://www.springframework.org/schema/security"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:mongo="http://www.springframework.org/schema/data/mongo"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.1.xsd
http://www.springframework.org/schema/data/mongo http://www.springframework.org/schema/data/mongo/spring-mongo-1.0.xsd
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.1.xsd">
and I get in eclipse the following error on the file:
The errors below were detected when validating the file
“spring-mongo-1.0.xsd” via the file “servlet-context.xml”. In most
cases these errors can be detected by validating
“spring-mongo-1.0.xsd” directly. However it is possible that errors
will only occur when spring-mongo-1.0.xsd is validated in the context
of servlet-context.xml.
src-resolve:Cannot resolve the name ‘repository:repository’to a(n) ‘type definition’ componenent Location: line 110
The project still works, but I am trying to get rid of this error. Any ideas?
Per @francadaval the solution was to change the link to the xsd to:
springframework.org/schema/data/mongo/spring-mongo.xsd