Community
Participate
Working Groups
Build Identifier: 20100917-0705 I am trying to use Extensible XML authoring in my project Spring configuration files and I like the eclipse XML Editor to validate the files correctly (+ adding code completion). This is how the spring configuration file looks like: {code} <?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:custom="http://www.myhost.com/2011/my-custom-scheme" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd http://www.myhost.com/2011/my-custom-scheme http://www.myhost.com/2011/my-custom-scheme.xsd"> <custom:my-element /> </beans> {code} The custom-scheme is implemented correctly, but the scheme file is not located at the specified URL 'http://www.myhost.com/2011/my-custom-scheme.xsd' but located in a JAR file which is added to my project classpath, as configured in META-INF/spring.schemas. The XML editor does not validate my configuration file, that is why I try to add a special entry to my XMLCatalog. I created my own XML Catalog file and use the 'Next Catalog' option in the Preferences > XML > XML Catalog > Add... dialog. If the entry in my XML-Catalog file looks like this, validation and code-completion works correctly only if I remove the corresponding schemaLocation from my XML file: {code} <uri name="http://www.myhost.com/2011/my-custom-scheme" uri="jar:file:/C:/path/custom.jar!/path/to/my-custom-scheme.xsd"/> {code} Unfortunatly the spring application-context does not longer know how to resolve the custom-scheme, because the schemaLocation is required. Trying the following entry in the XML Catalog file does not fix the problem: {code} <uri name="http://www.myhost.com/2011/my-custom-scheme.xsd" uri="jar:file:/C:/path/custom.jar!/path/to/my-custom-scheme.xsd"/> {code} Validation and code-completion doesn't work at all. Reproducible: Always Steps to Reproduce: See details, or: Write an xml file and a schema. Put the Schema into your classpath, try to link the schemaLocation to the schema in classpath.