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 Frank-Ralph Reiser <ma...@frank-ralph.de> on 2004/09/07 11:03:07 UTC

Request formed from WSDL doesn't have the method name?

One of my web service classes deployed with axis has e.g. a method

public Data findCityByName(String name) {...}

which returns a Data object containing an array of City objects.

Consuming that webservice using an JSP client with generated stubs by wsdl2java
and either apache axis works without any problems.
But when consuming it with e.g. nuSOAP (PHP) or MS SOAP 3.0, the request doesn't
contain the method name.
Since the deployed ws class contains several deployed methods, axis simply calls
the first method with matching parameters.

When I write the request message by hand, as it should be, it works as wanted.


Did I deploy the webservice wrong?

<deployment name="test"
	xmlns="http://xml.apache.org/axis/wsdd/"
	xmlns:java="http://xml.apache.org/axis/wsdd/providers/java"
	xmlns:xsi="http://www.w3.org/2000/10/XMLSchema-instance">
	<service name="WS" 
		provider="java:RPC" 
		style="document"
		use="encoded">
		<parameter name="className" value="de.frr.webservice.WS"/>
		<parameter name="allowedMethods" value="*"/>
		<parameter name="sendMultiRefs" value="false"/>
		<parameter name="sendXsiTypes" value="true"/>
	</service>
</deployment>


Or is there anything else I should have a look at?


Thanks in advance,

Frank-Ralph Reiser




Re: Request formed from WSDL doesn't have the method name?

Posted by Frank-Ralph Reiser <ma...@frank-ralph.de>.
Am Tue, 07 Sep 2004 11:22:23 +0200 schrieb WAJSBERG Julien RD-BIZZ:
>>Consuming that webservice using an JSP client with generated stubs 
>>by wsdl2java and either apache axis works without any problems.
>>But when consuming it with e.g. nuSOAP (PHP) or MS SOAP 3.0, the 
>>request doesn't contain the method name.
>>
>>Did I deploy the webservice wrong?
> 
> Use :
> style="wrapped"

Thanks a lot. undeploying and re-deploying the ws in wrapped style solved
the issues with php/nuSOAP.

But apparently I now have problems consuming that ws with java (apache
axis) with generated classes and stubst via wsdl2java...

When invoking e.g. a JSP that calls the service, I get some error like
this:

HTTP ERROR: 500
nested exception is org.xml.sax.SAXException
Invalid element in de.frr.webservice.Data: getTestDataReturn

Is there anything I should pay attention when generating the stubs of a
wrapped style ws?



Frank-Ralph Reiser



Re: Request formed from WSDL doesn't have the method name?

Posted by WAJSBERG Julien RD-BIZZ <ju...@rd.francetelecom.com>.
Frank-Ralph Reiser a écrit :

>One of my web service classes deployed with axis has e.g. a method
>
>public Data findCityByName(String name) {...}
>
>which returns a Data object containing an array of City objects.
>
>Consuming that webservice using an JSP client with generated stubs by wsdl2java
>and either apache axis works without any problems.
>But when consuming it with e.g. nuSOAP (PHP) or MS SOAP 3.0, the request doesn't
>contain the method name.
>Since the deployed ws class contains several deployed methods, axis simply calls
>the first method with matching parameters.
>
>When I write the request message by hand, as it should be, it works as wanted.
>
>
>Did I deploy the webservice wrong?
>  
>

Use :
style="wrapped"

-- 
Julien