You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by James Arbo <ar...@copyright.com> on 2007/05/16 07:13:42 UTC
configuring Service to use RPC style
Hi All,
I'm struggling with this and hoping someone can help. I'm trying to
create a simple "sayHello" Axis2 service that will accept a String and
return a String. I want this service to use RPC/literal style. The wsdl
that gets auto generated by Axis2 specifes document/literal and calling
the service results in a document/literal message. I have not been able
to figure out how to tell Axis that the service should use style "RPC".
The wsdl that Axis2 generates at run-time contains the following
references to document/literal:
- <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
<wsdl:binding name="helloserviceSOAP11Binding"
type="axis2:helloservicePortType">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http"
style="document" />
- <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
<wsdl:operation name="sayHello">
<soap:operation soapAction="urn:sayHello" style="document" />
- <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
<wsdl:input>
<soap:body use="literal" />
</wsdl:input>
- <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
<wsdl:output>
<soap:body use="literal" />
</wsdl:output>
I'm guessing there is a parameter that would be specified in the
services.xml but I'm unable to find anything online.
Thanks for your help.
-Jay
Re: configuring Service to use RPC style
Posted by Charitha Kankanamge <ch...@wso2.com>.
Hi James,
You can use java2wsdl to get wsdl generated with RPC/literal style.
Specify -st and -u as follows.
C:\Axis2\axis2-SNAPSHOT\bin>java2wsdl.bat -cn Helloservice -cp . -o
C:\Axis2\axis2-SNAPSHOT\bin\out -st rpc -u literal
regards
Charitha
James Arbo wrote:
> Hi All,
>
> I’m struggling with this and hoping someone can help. I’m trying to
> create a simple “sayHello” Axis2 service that will accept a String and
> return a String. I want this service to use RPC/literal style. The
> wsdl that gets auto generated by Axis2 specifes document/literal and
> calling the service results in a document/literal message. I have not
> been able to figure out how to tell Axis that the service should use
> style “RPC”.
>
> The wsdl that Axis2 generates at run-time contains the following
> references to document/literal:
>
> *-*
> <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
> <wsdl:binding name="*helloserviceSOAP11Binding*"
> type="*axis2:helloservicePortType*">
>
> * * <soap:binding transport="*http://schemas.xmlsoap.org/soap/http*"
> style="*document*" />
>
> *-*
> <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
> <wsdl:operation name="*sayHello*">
>
> * * <soap:operation soapAction="*urn:sayHello*" style="*document*" />
>
> *-*
> <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
> <wsdl:input>
>
> * * <soap:body use="*literal*" />
>
> * * </wsdl:input>
>
> *-*
> <http://10.1.2.147:8988/naples-prelim/services/helloservice?wsdl##>
> <wsdl:output>
>
> * * <soap:body use="*literal*" />
>
> * * </wsdl:output>
>
> I’m guessing there is a parameter that would be specified in the
> services.xml but I’m unable to find anything online.
>
> Thanks for your help.
>
> -Jay
>
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org