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 Aravind Chavar <ar...@hotmail.com> on 2002/06/24 21:00:07 UTC
Is it a bug in AdminClient?
Hi,
I have created a sample webservice , which makes use of complex data types
Class implementing the service is
package SpareParts;
import java.io.*;
import java.util.*;
public class SparePartService{
public SparePartBean getSparePart(String partSku){
SparePartBean result = new SparePartBean();
result.setPrice((float)12.33);
result.setDescription("Sungard Test Part");
result.setSku(partSku);
return result;
}
public String addSparePart(SparePartBean part){
return "Sungard part added successfully!!" + part.getSku();
}
}
WSDD for this class is
<deployment
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="SparePartService" provider="java:RPC">
<parameter name="className" value="SpareParts.SparePartService" />
<parameter name="allowedMethods" value="getSparePart addSparePart" />
</service>
</deployment>
I am deploying this web service using
java org.apache.axis.client.AdminClient deploy.wsdd
-lhttp://localhost:8080/axis/services/AdminService
WSDL returned on using URL
http://localhost:8080/axis/services/SparePartService?wsdl is as
follows.What I am not understanding is xmlns:tns1="http://SpareParts" .Is
it a bug in Adminclient utility?
<?xml version="1.0" encoding="UTF-8" ?>
- <wsdl:definitions
targetNamespace="http://localhost:8080/axis/services/SparePartService"
xmlns="http://schemas.xmlsoap.org/wsdl/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:impl="http://localhost:8080/axis/services/SparePartService-impl"
xmlns:intf="http://localhost:8080/axis/services/SparePartService"
xmlns:tns1="http://SpareParts" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <types>
- <schema targetNamespace="http://SpareParts"
xmlns="http://www.w3.org/2001/XMLSchema">
- <complexType name="SparePartBean">
- <sequence>
<element name="sku" nillable="true" type="xsd:string" />
<element name="price" type="xsd:float" />
<element name="description" nillable="true" type="xsd:string" />
</sequence>
</complexType>
<element name="SparePartBean" nillable="true" type="tns1:SparePartBean" />
</schema>
</types>
- <wsdl:message name="addSparePartResponse">
<wsdl:part name="return" type="xsd:string" />
</wsdl:message>
- <wsdl:message name="getSparePartResponse">
<wsdl:part name="return" type="tns1:SparePartBean" />
</wsdl:message>
- <wsdl:message name="getSparePartRequest">
<wsdl:part name="in0" type="xsd:string" />
</wsdl:message>
- <wsdl:message name="addSparePartRequest">
<wsdl:part name="in0" type="tns1:SparePartBean" />
</wsdl:message>
- <wsdl:portType name="SparePartService">
- <wsdl:operation name="getSparePart" parameterOrder="in0">
<wsdl:input message="intf:getSparePartRequest" />
<wsdl:output message="intf:getSparePartResponse" />
</wsdl:operation>
- <wsdl:operation name="addSparePart" parameterOrder="in0">
<wsdl:input message="intf:addSparePartRequest" />
<wsdl:output message="intf:addSparePartResponse" />
</wsdl:operation>
</wsdl:portType>
- <wsdl:binding name="SparePartServiceSoapBinding"
type="intf:SparePartService">
<wsdlsoap:binding style="rpc"
transport="http://schemas.xmlsoap.org/soap/http" />
- <wsdl:operation name="getSparePart">
<wsdlsoap:operation soapAction="" />
- <wsdl:input>
<wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="getSparePart" use="encoded" />
</wsdl:input>
- <wsdl:output>
<wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="http://localhost:8080/axis/services/SparePartService"
use="encoded" />
</wsdl:output>
</wsdl:operation>
- <wsdl:operation name="addSparePart">
<wsdlsoap:operation soapAction="" />
- <wsdl:input>
<wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="addSparePart" use="encoded" />
</wsdl:input>
- <wsdl:output>
<wsdlsoap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
namespace="http://localhost:8080/axis/services/SparePartService"
use="encoded" />
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
- <wsdl:service name="SparePartServiceService">
- <wsdl:port binding="intf:SparePartServiceSoapBinding"
name="SparePartService">
<wsdlsoap:address
location="http://localhost:8080/axis/services/SparePartService" />
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
_________________________________________________________________
Chat with friends online, try MSN Messenger: http://messenger.msn.com
RE: Is it a bug in AdminClient?
Posted by "Arne M. Degenring" <ar...@degenring.de>.
> -----Original Message-----
> From: Aravind Chavar [mailto:arvindbc@hotmail.com]
> Sent: Monday, June 24, 2002 9:00 PM
> To: axis-user@xml.apache.org
> Subject: Is it a bug in AdminClient?
>
>
> Hi,
> I have created a sample webservice , which makes use of
> complex data types
[...]
> WSDL returned on using URL
> http://localhost:8080/axis/services/SparePartService?wsdl is as
> follows.What I am not understanding is
> xmlns:tns1="http://SpareParts" .Is
> it a bug in Adminclient utility?
Hi Aravind,
have you declared a BeanMapping for your SparPartBean? You can do this
by adding a
<beanMapping languageSpecificType=... qname=.../>
statement to your WSDD. Refer to the docs for details.
Arne