You are viewing a plain text version of this content. The canonical link for it is here.
Posted to soap-user@ws.apache.org by Zafar Nisthar <Za...@eRunway.com> on 2001/08/09 10:47:49 UTC

RE: Invoking NasdaqQuotes sample web service (IBM WSTK2.3 proble m)

Finally got it to work 

Thanks to your help !

-zaf




-----Original Message-----
From: James M Snell [mailto:jasnell@us.ibm.com]
Sent: Thursday, August 09, 2001 1:24 PM
To: soap-user@xml.apache.org
Subject: RE: Invoking NasdaqQuotes sample web service (IBM WSTK2.3
proble m)


Right, I believe its the beandeserializer.  And yes, the WSDL's need to be 
out on your Web server.

- James Snell
     Software Engineer, Emerging Technologies, IBM
     James M Snell/Fresno/IBM - jasnell@us.ibm.com
    "No, 'being created in God's image' does not mean I'll have this 
project done in seven days!" - Anon.

Please respond to soap-user@xml.apache.org 
To:     "'soap-user@xml.apache.org'" <so...@xml.apache.org>
cc:     James M Snell/Fresno/IBM@IBMUS 
Subject:        RE: Invoking NasdaqQuotes sample web service (IBM WSTK2.3
proble m)



Thanks,

Its not the StringDeserializer because its the NasdaqQuote object that it
couldn't deserialize.

By the way in the tutorial, in the deploy batch file what does it mean 
when
it says "remember to copy all of the wsdl files located in ./deploy to a
well known location on your webserver"?

is the client get the wsdl's from the web server?

zaf

-----Original Message-----
From: James M Snell [mailto:jasnell@us.ibm.com]
Sent: Thursday, August 09, 2001 12:17 PM
To: soap-user@xml.apache.org
Subject: RE: Invoking NasdaqQuotes sample web service (IBM WSTK2.3
proble m)


The tooling that creates proxies from a WSDL document doesn't handle
custom complex xml data very well.  Take a look at the
NasdaqQuotesClient.java for information about how to define the
serializers.

Also, I think in Apache SOAP 2.2, the "StringSerializer" class went away,
so the code needs to be changed to use "StringDeserializer".  Could be
wrong because I'm just now getting back to updating the code.

- James Snell
     Software Engineer, Emerging Technologies, IBM
     James M Snell/Fresno/IBM - jasnell@us.ibm.com
    "No, 'being created in God's image' does not mean I'll have this
project done in seven days!" - Anon.

Please respond to soap-user@xml.apache.org
To:     "'soap-user@xml.apache.org'" <so...@xml.apache.org>
cc:
Subject:        RE: Invoking NasdaqQuotes sample web service (IBM WSTK2.3
proble        m)



Thanks Tom,

I did mean invoking. I did check with the apache trouble shooting document
and figured that the client couldn't find the Deserialiser.

But the thing about WSTK2.3 is the Sevice Interface WSDL is used to
generate
something called a service proxy. The service proxy contains the code to
access and then invoke the web service. So I can't alter the mapping in
the
client code or can I ??

I was hoping other users of WSTK2.3 might have encountered this problem.

zaf

-----Original Message-----
From: Tom Myers [mailto:tommyers@dreamscape.com]
Sent: Wednesday, August 08, 2001 6:52 PM
To: soap-user@xml.apache.org
Subject: RE: Deploying NasdaqQuotes sample web service (IBM WSTK2.3
proble m)


At 01:01 PM 8/8/2001 +0600, Zafar Nisthar wrote:
...
>The following Exception occurs when i try to deploy:

umm, I think you mean, when you try to invoke the deployed service?

>---------------------------------------------------------------------------
-
>--
>NasdaqQuotes Service Found.... preparing proxy...
>
>
>NasdaqQuotes Service Proxy Initialized... invoking service...
>
>Exception in thread "main" com.ibm.wstk.WSTKException: RPC exception in
>method invocation.
>---------------------------------------------------------------------------
-
>--
>   Nested exception is:
>
>   [SOAPException: faultCode=SOAP-ENV:Client; msg=No Deserializer found
to
>deserialize a 'urn:nasdaqquotes-service:NasdaqQuote' using encoding style
>'http://schemas.xmlsoap.org/soap/encoding/'.;

Your client is failing to deserialize the answer; you'll find this in the
troubleshooting guide,e.g.
   ...\soap-2_2\docs\trouble\index.html :
>No Deserializer found to deserialize a 'XYZ' using encoding style 'FOO'
>The Apache SOAP code received a SOAP envelope (as a request if its on the
server
>side or in a response if its on the client) containing an XML element of
schema
>type XYZ and encoded using encoding style FOO. The exception occurred
because the
>runtime was unable to find a deserializer to deserialize such types
encoded
in
>that style. The solution is to add another type mapping to the deployment
>descriptor (if the problem occurred on the server side) or add another
>mapping to the client code (if the problem occurred on the client side).

In this case, look at the addressbook example code for stuff like

>     BeanSerializer beanSer = new BeanSerializer();
>     smr.mapTypes(Constants.NS_URI_SOAP_ENC,
>                  new QName("urn:xml-soap-address-demo", "address"),
>                  Address.class, beanSer, beanSer);

and probably you want something vaguely resembling
>     smr.mapTypes(Constants.NS_URI_SOAP_ENC,
>                  new QName("urn:nasdaqquotes-service", "NasdaqQuote"),
>                  NasdaqQuote.class, beanSer, beanSer);

(That assumes that your actual quote class is called NasdaqQuote and can
be
deserialized by the BeanSerializer class, of course.) But I don't know how
this sort of issue interrelates with IBM WSTK2.3....

Tom Myers