Camel
  1. Camel
  2. CAMEL-4361

Improve validator to accept several schemas

    Details

    • Type: Improvement Improvement
    • Status: Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: 2.8.0
    • Fix Version/s: None
    • Component/s: camel-spring
    • Labels:
      None
    • Estimated Complexity:
      Unknown

      Description

      The current implementation only allows for one given xsd schema.
      I have some messages which have two namespaces. The outer schema declares some elements with lax processing.
      By providing a http://static.springsource.org/spring-ws/sites/1.5/spring-xml/apidocs/org/springframework/xml/xsd/XsdSchemaCollection.html which references both schemas I would be able to validate the whole message - and not just the outermost one.

      Either the existing implementation will have to be altered to allow for several paths, or it can be extended to reference a schemacollection.

        Activity

        Hide
        Christian Müller added a comment -

        David, do you plan to provide a patch for it? We love contributions...

        Starting from Camel 2.9.0, the validator component does no longer depend on Spring...

        Show
        Christian Müller added a comment - David, do you plan to provide a patch for it? We love contributions... Starting from Camel 2.9.0, the validator component does no longer depend on Spring...
        Hide
        David J. M. Karlsen added a comment -

        Hm, I see ./src/test/resources/org/apache/camel/component/validator/camelContext.xml in camel-spring on trunk which is 2.9?
        However I do not find the implementation of the component.

        Where is the new validator component?

        Show
        David J. M. Karlsen added a comment - Hm, I see ./src/test/resources/org/apache/camel/component/validator/camelContext.xml in camel-spring on trunk which is 2.9? However I do not find the implementation of the component. Where is the new validator component?
        Hide
        Claus Ibsen added a comment -

        Its moved to camel-core as it no longer depend on Spring JARs, from Camel 2.9 onwards.

        There are still some unit tests in camel-spring to ensure it also works when configuring in Spring XML DSLs.

        Show
        Claus Ibsen added a comment - Its moved to camel-core as it no longer depend on Spring JARs, from Camel 2.9 onwards. There are still some unit tests in camel-spring to ensure it also works when configuring in Spring XML DSLs.
        Hide
        David J. M. Karlsen added a comment -

        So if "my" component will depend on: http://static.springsource.org/spring-ws/sites/1.5/spring-xml/apidocs/org/springframework/xml/xsd/commons/CommonsXsdSchema.html and org.apache.ws.commons.schema.XmlSchemaCollection then i guess I should stick it into camel-spring?

        Show
        David J. M. Karlsen added a comment - So if "my" component will depend on: http://static.springsource.org/spring-ws/sites/1.5/spring-xml/apidocs/org/springframework/xml/xsd/commons/CommonsXsdSchema.html and org.apache.ws.commons.schema.XmlSchemaCollection then i guess I should stick it into camel-spring?
        Hide
        Claus Ibsen added a comment -

        No the component should not be depend on Spring or any other 3rd party JARs. It should use the API from the JDK.

        Show
        Claus Ibsen added a comment - No the component should not be depend on Spring or any other 3rd party JARs. It should use the API from the JDK.
        Hide
        Claus Ibsen added a comment -

        Any update on this?

        Show
        Claus Ibsen added a comment - Any update on this?

          People

          • Assignee:
            Unassigned
            Reporter:
            David J. M. Karlsen
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:

              Development