Next in thread →
Next in month →
Re: [xml-dev] relax ng and wsdl
On Mon, Oct 17, 2005 at 12:56:36PM +0200, Robin Berjon wrote: >De Heer, Robert S - San Mateo, CA - Contractor wrote: >>I have been working on importing a relax ng schema into a wsdl and have >>run into some problems with namespaces/getting wsdl2java to recognize >>the relax ng schema. Has anyone done this successfully? Could you >>provide an example? > >Unfortunately, I don't think anyone has actually implemented RNG support >in a WSDL processor (I'd be happy to learn otherwise though). There's a >discussion of how it would be done here: > > http://www.w3.org/TR/2005/NOTE-wsdl20-altschemalangs-20050817/ The note is, please be aware, for WSDL 2.0, not WSDL 1.1. I believe that wsdl2java, the tool mentioned, operates on WSDL 1.1 documents. While it is possible that the techniques mentioned in the note could be implemented for WSDL 1.1, it would be a more complex effort, I suspect. wsdl:definitions/wsdl:types *is* an extension point, so it's feasible there. Unfortunately, wsdl:definitions/wsdl:message (and child elements, particular wsdl:part) are not extensible (http://www.w3.org/TR/wsdl#A3), so adapting a different "type" system (schema language) to WSDL 1.1 would involve redefining the use of wsdl:part's @type or @element attributes. The problem extends to the definition of the SOAP binding schema as well; either the behavior of certain elements and attributes must be redefined, or alternate constructs must be defined anew. This is not to say that it can't be done, just to say that it probably can't be done as gracefully (by comparison only, mind) as the referenced WSDL 2.0 note does for RNG and DTD. And that is, in large part, because the WSD WG made strong efforts to ensure that WSDL 2.0 wasn't tied to W3C XML Schema as the only possible schema language (and produced the note more as "proof of concept" than anything else: "here's how you could do some alternative schema language, go ye and do likewise"). A particular problem when an alternative schema language is defined (for either version of WSDL) is: what happens when there are competing definitions for the same construct? That is, what if the extension provides an alternate mechanism for pointing at schema constructs, and both pointing mechanisms exist within some definition? (for example, what if a message structure has a pointer both to a DTD definition and to a W3C schema definition? These are almost certainly incompatible to a degree, since DTD definitions cannot "type" elements) See http://www.w3.org/TR/wsdl20/#other-types, especially the warning at the end for the resolution in WSDL 2.0: "behavior is undefined" if there are definitions in two different schema languages. So. WSDL 2.0 is not (yet) in CR, so I doubt that available tools (like wsdl2java) can cope with its (changed) syntax (it *is* 2.0, not 1.2; there are *lots* of changes). Adapting the techniques suggested in the referenced Note to WSDL 1.1 is likely to be painful at best. Feedback on the utility of the extension mechanism for WSDL 2.0 would probably be appreciated, though. Amy! (speaking entirely for herself (and *all* the *little people* (no, sorry, got carried away there, it's just us (you mean "just me" (oh, right, thanks))))) -- Amelia A. Lewis amyzing {at} talsever.com The law, in its majestic equality, forbids the rich as well as the poor to sleep under bridges, to beg in the streets, and to steal bread. -- Anatole France, "Le Lys Rouge"
Next in thread →
Next in month →