javaxmlmavenxsdektorp

Failed to read CouchDb schema from classpath


I am using this guide to configure CouchDb via Spring-boot: link. The problem arises when this XML configuration 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:couchdb="http://www.ektorp.org/schema/couchdb"
xsi:schemaLocation="
    http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
    http://www.ektorp.org/schema/couchdb http://www.ektorp.org/schema/couchdb/couchdb.xsd
">

 <couchdb:database name="myDatabase" url="http://localhost:5984"/> 


</beans>

cannot be validated, because ektorp xml schema can't be read. When I check via browser link of its schema, there isn't any, but there is one definitively in maven dependencies. But when I switch this line

http://www.ektorp.org/schema/couchdb/couchdb.xsd

into

classpath:couchdb.xsd

It won't be read either, even it's in one of the maven dependencies under the name couchdb.xsd. (You can inspect that file on github).

How I can force XML reader to look into maven dependencies in order to find proper schema file?


Solution

  • The problem is annoying like every other which occurs because of Eclipse's bugs. I just deleted config file and created it again, but without to validate xml schema, and everything works fine.

    P.S. Configuration in the question is correct, there is no need to pull xml schema from local maven repository, i.e. from classpath.