W3C home > Mailing lists > Public > www-ws@w3.org > November 2004

RE: Class as WS return parameter

From: Daniela CLARO <daniela.claro@eseo.fr>
Date: Tue, 16 Nov 2004 19:17:42 +0100
To: <www-ws@w3.org>
Message-Id: <20041116181746.E22CD12D1@harley.eseo.fr>

Increasing my explanation, when I run without server-config.wsdd I receive
this error:

java.io.IOException: No serializer found for class ReturnFlight in registry

Thank you again!!

-----Message d'origine-----
De : www-ws-request@w3.org [mailto:www-ws-request@w3.org] De la part de
Daniela CLARO
Envoyé : mardi 16 novembre 2004 19:09
À : www-ws@w3.org
Objet : Class as WS return parameter

Hi all,
 I am having a problem with my web service. I've created a web service that
it has a signature as below:

public ReturnFlight findFlight(String fromCity, String toCity, String
dtDeparture, String dtArrival){

Where ReturnFlight is a class that I defined earlier with two attibutes. 

I am using AXIS 1.2 and I put this class (ReturnedFlight) into
WEB-INF/classes. My web service is published on
http://localhost:8080/Flight.jws. And the problem is that when I run my
simple Axis example to execute my web service, at first time it gave me a
message that I did not have serialized my class bean(ReturnedFlight). 

 I've tried to solve this problem putting the server-config.wsdd in my
WEB-INF directory, but when I do that I receive an error execution on my
http://localhost:8080/Flight.jws. The problem is actually occuring when I
try this code in AXIS:

 call.setReturnType( XMLType.XSD_ANYTYPE );  ReturnFlight ret = new
       ret = (ReturnFlight) call.invoke( new Object [] { fromCity,
toCity,dtDeparture,dtArrival });

I did not get any answer because I think it did not know how to work with my
ReturnFlight class. 

One more thing, if I am monitoring on the server side(Tomcat), I can saw
that my service has got actually the result that I want, but it did not
arrive to the client side. 

What do I must do to manage a class on returning parameters? 

Here below, I put my server-config.wsdd, I do not know if it is correctly or

Help me, please!!!

<?xml version="1.0" encoding="UTF-8"?>
<deployment xmlns="http://xml.apache.org/axis/wsdd/"

<service name= "Flight" provider= "java:RPC" style="rpc" use= "encoded"> 

<parameter name= "wsdlTargetNamespace" value=
<parameter name= "wsdlServiceElement" value= "Flight"/> <parameter name=
"wsdlServicePort" value= "Flight"/> <parameter name= "className" value=
"ReturnFlight"/> <parameter name= "wsdlPortType " value= "Flight"/> 

<operation name= "findFlight" qname= "operNS:findFlight" 
    xmlns:operNS= "http://localhost:8080/travelws/Flight.jws"
	returnQName= "findFlightReturn" returnType= "rtns:ReturnFlight"
	xmlns:rtns= "http://DefaultNamespace"> </operation > <parameter
name= "allowedMethods " value= "findFlight"/> 

xmlns:ns= "http://DefaultNamespace" 
qname= "ns:ReturnFlight" 
type= "ReturnFlight" 
serializer= "org.apache.axis.encoding.ser.BeanSerializerFactory " 
deserializer= "org.apache.axis.encoding.ser.BeanDeserializerFactory " 
encodingStyle= " http://schemas.xmlsoap.org/soap/encoding/" /> </service >

Thank you so much,
Received on Tuesday, 16 November 2004 18:17:49 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:37:11 UTC