You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Melissa Turner <mj...@apple.com> on 2002/10/03 02:24:40 UTC
WSDL generation broken?
Is WSLD generation broken in some way, or do I just not understand how
it's supposed to work? (This is all with RC2 in Tomcat 4.0.5).
I create a Java class that I want to expose as a service
(BustedWSDL.java, below). I deploy it (as per the userguide) using a
static deploy.wsdd file (also below).
In the deploy.wsdd, I set the service name to "TestWSDL". However, when
I look at the WSDL (http://localhost:8080/axis/services/TestWSDL?wsdl),
the WSDL (also below) says that the service name is "BustedWSDLService".
I also note that a client can invoke the service as "TestWSDL", but not
as "BustedWSDLService".
Is this the correct behavior? It seems like the WSDL generated doesn't
match the actual deployed service.
+Melissa
********** BustedWSDL.java **********
import org.apache.axis.*;
public class BustedWSDL extends Object {
public String reversi(String s) { return new
StringBuffer(s).reverse().toString(); }
}
**********
********** deploy.wsdd **********
<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns="http://xml.apache.org/axis/wsdd/"
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">
<service name="TestWSDL" provider="java:RPC">
<parameter name="className" value="BustedWSDL"/>
<parameter name="allowedMethods" value="reversi"/>
</service>
</deployment>
**********
********** WSDL **********
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions
targetNamespace="http://localhost:8080/axis/services/TestWSDL"
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:apachesoap="http://xml.apache.org/xml-soap"
xmlns:impl="http://localhost:8080/axis/services/TestWSDL"
xmlns:intf="http://localhost:8080/axis/services/TestWSDL"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"><wsdl:types/>
<wsdl:message name="reversiResponse">
<wsdl:part name="reversiReturn" type="xsd:string"/>
</wsdl:message>
<wsdl:message name="reversiRequest">
<wsdl:part name="in0" type="xsd:string"/>
</wsdl:message>
<wsdl:portType name="BustedWSDL">
<wsdl:operation name="reversi" parameterOrder="in0">
<wsdl:input message="intf:reversiRequest" name="reversiRequest"/>
<wsdl:output message="intf:reversiResponse"
name="reversiResponse"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="TestWSDLSoapBinding" type="intf:BustedWSDL">
<wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="reversi">
<wsdlsoap:operation soapAction=""/>
<wsdl:input name="reversiRequest">
<wsdlsoap:body
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="http://localhost:8080/axis/services/TestWSDL" use="encoded"/>
</wsdl:input>
<wsdl:output name="reversiResponse">
<wsdlsoap:body
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="http://localhost:8080/axis/services/TestWSDL" use="encoded"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="BustedWSDLService">
<wsdl:port binding="intf:TestWSDLSoapBinding" name="TestWSDL">
<wsdlsoap:address
location="http://localhost:8080/axis/services/TestWSDL"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
**********