Re: R: mistake in SOAP envelope XMLSchema
Christopher B Ferris <[email protected]> Wed, 14 Nov 2007 12:31:50 -0500
| Newsgroups | gmane.text.xml.distributed |
|---|---|
| Message-ID | <OFD8388DF1.1C018CD9-ON85257393.005F6B3C-85257393.00602818@us.ibm.com> |
This is a multipart message in MIME format. --=_alternative 005FDFE685257393_= Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable Ah, clearly I misunderstood your request. As for SOAP1.1, that specification, nor it's schema is maintained by the=20 XML Protocol WG. The WS-I Basic Profile [1], however, aligns with the direction that the XML=20 Protocol WG took in disallowing use of the soap:encodingStyle attribute on the soap:envelope element: R1005 An ENVELOPE MUST NOT contain soap:encodingStyle attributes on any of = the elements whose namespace name is=20 "http://schemas.xmlsoap.org/soap/envelope/".=20 Since the WS-I Basic Profile is followed by most implementations, since it = helps to improve the interoperability of those implementations, it seems to me that any change to the SOAP1.1 schema is=20 also unnecessary. [1] http://www.ws-i.org/Profiles/BasicProfile-1.1-2006-04-10.html Hope this helps, Christopher Ferris STSM, Software Group Standards Strategy email: [email protected] blog: http://www.ibm.com/developerworks/blogs/page/chrisferris phone: +1 508 234 2986 [email protected] wrote on 11/14/2007 09:48:17 AM: >=20 > Hi Christopher, >=20 > thank you for your answer. > Actually I was talking about SOAP 1.1 (not 1.2) and about this=20 XMLSchema: >=20 > http://schemas.xmlsoap.org/soap/envelope/ >=20 > which (as stated in the comment) appears to be the official SOAP 1.1 > schema. (Am I wrong?) > I agree with you: SOAP 1.2 does not allow the encodingStyle=20 > attribute to appear on the envelope element, but SOAP 1.1 (and its=20 > schema) should! >=20 > Best regards, >=20 > Alessandro Pira >=20 >=20 > Da: Christopher B Ferris [mailto:[email protected]]=20 > Inviato: mercoled=EC 14 novembre 2007 15.07 > A: Alessandro Pira > Cc: [email protected] > Oggetto: Re: mistake in SOAP envelope XMLSchema >=20 > Alessandro,=20 >=20 > The quoted text you cite is pretty clear. I have emphasized using CAPS.=20 >=20 > "SOAP 1.2 DOES NOT ALLOW the env:encodingStyle attribute to appear=20 > on the SOAP env:Envelope, whereas SOAP 1.1 allows it to appear on=20 > any element. SOAP 1.2 specifies specific elements where this=20 > attribute may be used."=20 >=20 > Additionally, from the SOAP1.2 specification [1]:=20 >=20 > "The encodingStyle attribute information item MAY appear on the=20 following:=20 > 1. A SOAP header block (see 5.2.1 SOAP header block).=20 > 2. A child element information item of the SOAP Body element=20 > information item (see 5.3.1 SOAP Body child Element) if that child=20 > is not a SOAP Fault element information item (see 5.4 SOAP Fault).=20 > 3. A child element information item of the SOAP Detail=20 > element information item (see 5.4.5.1 SOAP detail entry).=20 > 4. Any descendent of 1, 2, and 3 above.=20 > The encodingStyle attribute information item MUST NOT appear on any=20 > element other than above in a SOAP message infoset."=20 >=20 > The soap:encodingStyle attribute is NOT permitted to be included in=20 > on the soap:Envelope element. Therefore, the schema is correct.=20 >=20 > [1] http://www.w3.org/TR/soap12-part1/#soapencattr=20 >=20 > Cheers,=20 >=20 > Christopher Ferris > STSM, Software Group Standards Strategy > email: [email protected] > blog: http://www.ibm.com/developerworks/blogs/page/chrisferris > phone: +1 508 234 2986=20 >=20 > [email protected] wrote on 11/12/2007 05:44:25 AM: >=20 > > Hi all,=20 > >=20 > > I am writing to this mailing list since I think I found a mistake in > > the official xml schema for SOAP envelopes:=20 > >=20 > > http://schemas.xmlsoap.org/soap/envelope/=20 > >=20 > > The error involves the encodingStyle attribute which (as stated in=20 > > examples in the note and also in [1]) seems possible to use in the=20 > > Envelope element.=20 > > But the official XMLSchema (http://schemas.xmlsoap.org/soap/envelope/ > > ) forbids this since it states:=20 > >=20 > > [...]=20 > > <xs:complexType name=3D"Envelope"> > > <xs:sequence> > > <xs:element ref=3D"tns:Header" minOccurs=3D"0"/> > > <xs:element ref=3D"tns:Body" minOccurs=3D"1"/> > > <xs:any namespace=3D"##other" minOccurs=3D"0" maxOccurs=3D"unbounded= "=20 > > processContents=3D"lax"/> > > </xs:sequence> > > <xs:anyAttribute namespace=3D"##other" processContents=3D"lax"/> > > </xs:complexType>=20 > > [...]=20 > >=20 > > I think it should say namespace=3D"##any" in the xs:anyAttribute=20 > > element (or explicitly define the encodingStyle attribute).=20 > >=20 > > I wrote you because the company I work for publishes some=20 > > webservices for our customers, and we use 3rd party libraries for=20 > > managing SOAP communication. Now some of our customers for some=20 > > reason are accusing us to be not compliant to the official SOAP=20 > > protocol, which I think is not true, but even W3C XMLSchema=20 > > validator shows that the Envelope we use is not valid because of the > > "encodingStyle" attribute.=20 > >=20 > > Can you please check if it's possible to correct the XMLSchema?=20 > >=20 > > Thank you in advance for your time,=20 > >=20 > > Alessandro Pira=20 > >=20 > >=20 > > [1] : the SOAP 1.2 part 0 Primer in Chapter 6 (Changes Between SOAP=20 > > 1.1 and SOAP 1.2) states:=20 > >=20 > > "SOAP 1.2 does not allow the env:encodingStyle attribute to appear=20 > > on the SOAP env:Envelope, whereas SOAP 1.1 allows it to appear on=20 > > any element. SOAP 1.2 specifies specific elements where this=20 > > attribute may be used."=20 > >=20 > >=20 --=_alternative 005FDFE685257393_= Content-Type: text/html; charset="ISO-8859-1" Content-Transfer-Encoding: quoted-printable <br><font size=3D2 face=3D"sans-serif">Ah, clearly I misunderstood your req= uest.</font> <br> <br><font size=3D2 face=3D"sans-serif">As for SOAP1.1, that specification, nor it's schema is maintained by the XML Protocol WG. The WS-I</font> <br><font size=3D2 face=3D"sans-serif">Basic Profile [1], however, aligns w= ith the direction that the XML Protocol WG took in disallowing use of the</font> <br><font size=3D2 face=3D"sans-serif">soap:encodingStyle attribute on the soap:envelope element:</font> <br> <br><font size=3D3>R1005 An ENVELOPE MUST NOT contain </font><tt><font size= =3D3>soap:encodingStyle</font></tt><font size=3D3> attributes on any of the elements whose namespace name is "http://sche= mas.xmlsoap.org/soap/envelope/". </font> <br> <br><font size=3D2 face=3D"sans-serif">Since the WS-I Basic Profile is foll= owed by most implementations, since it helps to improve the interoperability of those</font> <br><font size=3D2 face=3D"sans-serif">implementations, it seems to me that any change to the SOAP1.1 schema is also unnecessary.</font> <br> <br><font size=3D2 face=3D"sans-serif">[1] http://www.ws-i.org/Profiles/Bas= icProfile-1.1-2006-04-10.html</font> <br> <br><font size=3D2 face=3D"sans-serif">Hope this helps,</font> <br> <br><font size=3D2 face=3D"sans-serif">Christopher Ferris<br> STSM, Software Group Standards Strategy<br> email: [email protected]<br> blog: http://www.ibm.com/developerworks/blogs/page/chrisferris<br> phone: +1 508 234 2986</font> <br> <br><tt><font size=3D2>[email protected] wrote on 11/14/2007 09:4= 8:17 AM:<br> <br> > </font></tt> <br><tt><font size=3D2>> Hi Christopher,</font></tt> <br><tt><font size=3D2>> </font></tt> <br><tt><font size=3D2>> thank you for your answer.</font></tt> <br><tt><font size=3D2>> Actually I was talking about SOAP 1.1 (not 1.2) and about this XMLSchema:</font></tt> <br><tt><font size=3D2>> </font></tt> <br><tt><font size=3D2>> http://schemas.xmlsoap.org/soap/envelope/</font= ></tt> <br><tt><font size=3D2>> </font></tt> <br><tt><font size=3D2>> which (as stated in the comment) appears to be the official SOAP 1.1<br> > schema. (Am I wrong?)</font></tt> <br><tt><font size=3D2>> I agree with you: SOAP 1.2 does not allow the encodingStyle <br> > attribute to appear on the envelope element, but SOAP 1.1 (and its <br> > schema) should!</font></tt> <br><tt><font size=3D2>> </font></tt> <br><tt><font size=3D2>> Best regards,</font></tt> <br><tt><font size=3D2>> </font></tt> <br><tt><font size=3D2>> Alessandro Pira</font></tt> <br><tt><font size=3D2>> </font></tt> <br><tt><font size=3D2>> <br> > Da: Christopher B Ferris [mailto:[email protected]] <br> > Inviato: mercoled=EC 14 novembre 2007 15.07<br> > A: Alessandro Pira<br> > Cc: [email protected]<br> > Oggetto: Re: mistake in SOAP envelope XMLSchema<br> </font></tt> <br><tt><font size=3D2>> <br> > Alessandro, <br> > <br> > The quoted text you cite is pretty clear. I have emphasized using CAPS. <br> > <br> > "SOAP 1.2 DOES NOT ALLOW the env:encodingStyle attribute to appear <br> > on the SOAP env:Envelope, whereas SOAP 1.1 allows it to appear on <br> > any element. SOAP 1.2 specifies specific elements where this <br> > attribute may be used." <br> > <br> > Additionally, from the SOAP1.2 specification [1]: <br> > <br> > "The encodingStyle attribute information item MAY appear on the following: <br> > 1. A SOAP header block (see 5.2.1 SOAP header block). <br> > 2. A child element information item of the SOAP Body element <br> > information item (see 5.3.1 SOAP Body child Element) if that child <br> > is not a SOAP Fault element information item (see 5.4 SOAP Fault). <br> > 3. A child element information item of the SOAP Detail <br> > element information item (see 5.4.5.1 SOAP detail entry). <br> > 4. Any descendent of 1, 2, and 3 above. </font></tt> <br><tt><font size=3D2>> The encodingStyle attribute information item MUST NOT appear on any <br> > element other than above in a SOAP message infoset." <br> > <br> > The soap:encodingStyle attribute is NOT permitted to be included in <br> > on the soap:Envelope element. Therefore, the schema is correct. <br> > <br> > [1] http://www.w3.org/TR/soap12-part1/#soapencattr <br> > <br> > Cheers, <br> > <br> > Christopher Ferris<br> > STSM, Software Group Standards Strategy<br> > email: [email protected]<br> > blog: http://www.ibm.com/developerworks/blogs/page/chrisferris<br> > phone: +1 508 234 2986 <br> > <br> > [email protected] wrote on 11/12/2007 05:44:25 AM:<br> > <br> > > Hi all, <br> > > <br> > > I am writing to this mailing list since I think I found a mistake in<br> > > the official xml schema for SOAP envelopes: <br> > > <br> > > http://schemas.xmlsoap.org/soap/envelope/ <br> > > <br> > > The error involves the encodingStyle attribute which (as stated in <br> > > examples in the note and also in [1]) seems possible to use in the <br> > > Envelope element. <br> > > But the official XMLSchema (http://schemas.xmlsoap.org/soap/envel= ope/<br> > > ) forbids this since it states: <br> > > <br> > > [...] <br> > > <xs:complexType name=3D"Envelope"><br> > > <xs:sequence><br> > > <xs:element ref=3D"tns:Header" minOccur= s=3D"0"/><br> > > <xs:element ref=3D"tns:Body" minOccurs= =3D"1"/><br> > > <xs:any namespace=3D"##other" minOccurs= =3D"0" maxOccurs=3D"unbounded" <br> > > processContents=3D"lax"/><br> > > </xs:sequence><br> > > <xs:anyAttribute namespace=3D"##other" process= Contents=3D"lax"/><br> > > </xs:complexType> <br> > > [...] <br> > > <br> > > I think it should say namespace=3D"##any" in the xs:any= Attribute <br> > > element (or explicitly define the encodingStyle attribute). <br> > > <br> > > I wrote you because the company I work for publishes some <br> > > webservices for our customers, and we use 3rd party libraries for <br> > > managing SOAP communication. Now some of our customers for some <br> > > reason are accusing us to be not compliant to the official SOAP <br> > > protocol, which I think is not true, but even W3C XMLSchema <br> > > validator shows that the Envelope we use is not valid because of the<br> > > "encodingStyle" attribute. <br> > > <br> > > Can you please check if it's possible to correct the XMLSchema? <br> > > <br> > > Thank you in advance for your time, <br> > > <br> > > Alessandro Pira <br> > > <br> > > <br> > > [1] : the SOAP 1.2 part 0 Primer in Chapter 6 (Changes Between SOAP <br> > > 1.1 and SOAP 1.2) states: <br> > > <br> > > "SOAP 1.2 does not allow the env:encodingStyle attribute to appear <br> > > on the SOAP env:Envelope, whereas SOAP 1.1 allows it to appear on <br> > > any element. SOAP 1.2 specifies specific elements where this <br> > > attribute may be used." <br> > > <br> > > </font></tt> --=_alternative 005FDFE685257393_=--