You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@beehive.apache.org by "Jeremiah Johnson (JIRA)" <be...@incubator.apache.org> on 2005/05/02 22:06:08 UTC
[jira] Commented: (BEEHIVE-572) RPC literal generates invalid message with extra namsapces
[ http://issues.apache.org/jira/browse/BEEHIVE-572?page=comments#action_64288 ]
Jeremiah Johnson commented on BEEHIVE-572:
------------------------------------------
I just ran the samples with a recent distribution (post 165070) and the ReturnCreateAddressInBodyResult and out_param_body elements are now unqualified. Is there anything else keeping this bug open?
Here is the current response from http://localhost:8080/wsm-samplesWS/web/complex/RpcLiteralSample.jws?method=createAddressInBody
<?xml version="1.0" encoding="UTF-8"?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><soapenv:Body><createAddressInBodyResponse xmlns=""><ReturnCreateAddressInBodyResult>0</ReturnCreateAddressInBodyResult><out_param_body><ns1:city xmlns:ns1="http://beehive.apache.org/web/webservice/rpc-examples">Kirkland</ns1:city><ns2:phoneNumber xmlns:ns2="http://beehive.apache.org/web/webservice/rpc-examples"><ns2:areaCode>425</ns2:areaCode><ns2:exchange>555</ns2:exchange><ns2:number>1234</ns2:number></ns2:phoneNumber><ns3:state xmlns:ns3="http://beehive.apache.org/web/webservice/rpc-examples"><ns3:state>PA</ns3:state></ns3:state><ns4:streetName xmlns:ns4="http://beehive.apache.org/web/webservice/rpc-examples">NE Points Drive</ns4:streetName><ns5:streetNum xmlns:ns5="http://beehive.apache.org/web/webservice/rpc-examples">10230</ns5:streetNum><ns6:zip xmlns:ns6="http://beehive.apache.org/web/webservice/rpc-examples">98008</ns6:zip></out_param_body></createAddressInBodyResponse></soapenv:Body></soapenv:Envelope>
> RPC literal generates invalid message with extra namsapces
> ----------------------------------------------------------
>
> Key: BEEHIVE-572
> URL: http://issues.apache.org/jira/browse/BEEHIVE-572
> Project: Beehive
> Type: Bug
> Reporter: daryoush mehrtash
> Assignee: daryoush mehrtash
>
> THe response message to
> http://localhost:8080/wsm-samplesWS/web/complex/RpcLiteralSample.jws?method=createAddressInBody
> generates:
> <soapenv:Envelope>
> -
> <soapenv:Body>
> -
> <createAddressInBodyResponse>
> <ns1:ReturnCreateAddressInBodyResult>0</ns1:ReturnCreateAddressInBodyResult>
> -
> <ns2:out_param_body>
> <ns2:city>Kirkland</ns2:city>
> -
> <ns2:phoneNumber>
> <ns2:areaCode>425</ns2:areaCode>
> <ns2:exchange>555</ns2:exchange>
> <ns2:number>1234</ns2:number>
> </ns2:phoneNumber>
> -
> <ns2:state>
> <ns2:state>WA</ns2:state>
> </ns2:state>
> <ns2:streetName>NE Points Drive</ns2:streetName>
> <ns2:streetNum>10230</ns2:streetNum>
> <ns2:zip>98008</ns2:zip>
> </ns2:out_param_body>
> </createAddressInBodyResponse>
> </soapenv:Body>
> </soapenv:Envelope>
> The message is wrong. Below is the text from email send to me by Anne Thomas Manes
> Daryoush,
> The <ReturnCreateAddressResult> and <out_param_body> elements should be unqualified (in no namespace). I can't tell you what namespaces the child elements of <out_param_body> are supposed to be in without seeing the schema.
> According to the WS-I Basic Profile (which is the only definitive source of information for RPC/Literal), namespaces follow the following rules:
> The child element of the SOAP body (the autogenerated wrapper element
> -- in this case <createAddressResponse>) is in the namespace specified in the <wsdlsoap:body> definition in the WSDL binding:
> <wsdl:output name="impl:createAddressResponse">
> <wsdlsoap:body use="literal" namespace="some-uri"/>
> </wsdl:output>
> Since this element is unqualified in both your examples, I assume that you neglected to specify a namespace in your WSDL binding. (You should, though.)
> The children of this wrapper element (the autogenerated parameter
> elements) are in *no* namespace. These elements aren't defined in the WSDL -- only their types are defined:
> <wsdl:message name="createAddressResponse">
> <wsdl:part name="ReturnCreateAddressResult" type="xsd:int"/>
> <wsdl:part name="out_param_body" type="ns1:out_param_body"/>
> </wsdl:message>
> The children of <out_param_body> will be in the namespace(s) as defined by the schema that defines the out_param_body type (ns1). If you specified elementFormDefault="qualified", and you define all the children within that namespace, then the children of <out_param_body> will be in the ns1 namespace. But, if the children are defined in separate schemas, then they will be in different namespaces.
> For example, if the schema looks something like this:
> <xsd:complexType name="out_param_body">
> <xsd:sequence>
> <xsd:element ref="ns1:city"/>
> <xsd:element ref="ns2:phoneNumber"/>
> <xsd:element ref="ns3:state"/>
> ...
> </xsd:sequence>
> </xsd:complexType>
> then each child element will be in the appropriately referenced namespace.
> Anne
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira