Uploaded image for project: 'Spring Web Services'
  1. Spring Web Services
  2. SWS-413

SchemaCollection issues with classpath resources and relative schema imports

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.5.3, 1.5.4
    • Fix Version/s: 1.5.5
    • Component/s: OXM
    • Labels:
      None
    • Environment:
      Spring WS 1.5.3, war deployed to Jetty

      Description

      This issue is linked to the following thread http://forum.springframework.org/showthread.php?p=176210

      I store my schemas in a specific maven project together with the generated sources.

      client-messages.xsd import client-types.xsd

      In my war project, I configured the Spring-WS config file this way:

      <bean id="schemaCollection" class="org.springframework.xml.xsd.commons.CommonsXsdSchemaCollection">
      <property name="xsds">
      <list>
      <value>classpath:client-messages.xsd</value>
      </list>
      </property>
      <property name="inline" value="true" />
      </bean>

      When generating the wsdl, the framework complains that the client-types.xsd is not found.

      Would it be possible to enhance the XsdSchemaCollection (or to write a specific org.apache.ws.commons.schema.resolver.URIResolver) which can handle the import nicely ?

      Workaround is twofolds:

      • put the xsds in the war file
      • merge the xsds in one single file (no more import statement)
      1. ClasspathBaseUriResolver.java
        2 kB
        Patrick Crocker
      2. CommonsXsdSchemaCollection.java
        8 kB
        Patrick Crocker

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            arjen.poutsma Arjen Poutsma
            Reporter:
            patrick.crocker@gmail.com Patrick Crocker
          • Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: