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 Mark DeVries <de...@xyenterprise.com> on 2002/07/18 17:38:01 UTC

data confusion with base64 return from SOAP::Lite

I'm writing a web client in Apache SOAP that talks to a web server written in SOAP::Lite.  A lot of things work when the server returns a string (Case B, below) or a custom type (Case C).  But when the return is base64 (Case A), the Parameter access routines give garbled results.  Any ideas what I can do?

**********
Case A: "getgraphic" - returns "SOAP-ENC:base64";
getType() and getValue() do not fault, but give weird results
**********
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope [details omitted] >
<SOAP-ENV:Header>
 <namesp24:MD__Graphic xsi:type="namesp3:MD__Graphic"
  xmlns:namesp24="http://namespaces.soaplite.com/header">
  <_graphic xsi:type="xsd:string">default</_graphic>
 </namesp24:MD__Graphic>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
 <namesp25:getgraphicResponse xmlns:namesp25="MD/Graphic">
  <s-gensym60 xsi:type="SOAP-ENC:base64">
   JSFQUy1BZG9iZS0yL [much data omitted] khsBBQGUkgo=
  </s-gensym60>
 </namesp25:getgraphicResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

response.getReturnValue().getType():  class [B
response.getReturnValue().getValue(): [B@5e83f9
**********

**********
Case B: "library" - returns "xsd:string";
getType() and getValue() give reasonable results
**********
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope [details omitted] >
<SOAP-ENV:Body>
 <namesp20:libraryResponse xmlns:namesp20="MD/Graphic">
  <s-gensym48 xsi:type="xsd:string">jpeg default test</s-gensym48>
 </namesp20:libraryResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

response.getReturnValue().getType():  class java.lang.String
response.getReturnValue().getValue(): jpeg default test

**********
Case C: "new" - returns type "MD__Graphic"; custom serializer defined;
getType() and getValue() give reasonable results
**********
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope [details omitted] >
<SOAP-ENV:Body>
 <namesp21:newResponse xmlns:namesp21="MD/Graphic">
  <MD__Graphic xsi:type="namesp3:MD__Graphic">
   <_graphic xsi:type="xsd:string">default</_graphic>
  </MD__Graphic>
 </namesp21:newResponse>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

response.getReturnValue().getType():  class MD__Graphic
response.getReturnValue().getValue(): default

**********

Thanks,
Mark

--
*****  Mark.DeVries@xyenterprise.com
****  Xyvision Enterprise Solutions 781-756-5303
***  30 New Crossing Road, Reading MA 01867 USA



Re: tomcat 3.3.1

Posted by Carl CABOU <ca...@sncf.fr>.
Hi Gordon, I've managed to build WebService on Tomcat 3.3.1 using soap 
2.3.1.

In order to make tomcat find my classes that implement my webservice, I 
edit the tomcat.bat (or tomcat.sh on linux) in TOMCAT_HOME/bin. I know, 
that's not clean but I think this is the only way.
Search for the "set CLASSPATH= ...." string in tomcat.bat or "export 
CLASSPATH= .." in tomcat.sh. Add your paths and jar files there, 
re-start tomcat and try to use your webservice.

It did well for me.

Best Regards.

Carl.

Gordon Easton wrote:
> Anybody running SOAP on tomcat 3.3.1?
> I'm having a problem setting-up the classpath so that the SOAP engine
> can find the class files that make-up the web service.
> I guess what I really need to know is how to pass a classpath to a
> servlet in tomcat 3.3.1. Thanks.
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Autos - Get free new car price quotes
> http://autos.yahoo.com
> 
> --
> To unsubscribe, e-mail:   <ma...@xml.apache.org>
> For additional commands, e-mail: <ma...@xml.apache.org>
> 


-- 


Cordialement.

======================================================
Carl CABOU
SNCF - Direction de la Recherche et de la Technologie
Pôle Nouvelles Technologies de l'Information
Paris St-Lazare, bureau 295
Tel : 01 53 42 92 34
Poste : 31 92 34
======================================================


Re: tomcat 3.3.1

Posted by Carl CABOU <ca...@sncf.fr>.
Hi Gordon, I've managed to build WebService on Tomcat 3.3.1 using soap 
2.3.1.

In order to make tomcat find my classes that implement my webservice, I 
edit the tomcat.bat (or tomcat.sh on linux) in TOMCAT_HOME/bin. I know, 
that's not clean but I think this is the only way.
Search for the "set CLASSPATH= ...." string in tomcat.bat or "export 
CLASSPATH= .." in tomcat.sh. Add your paths and jar files there, 
re-start tomcat and try to use your webservice.

It did well for me.

Best Regards.

Carl.

Gordon Easton wrote:
> Anybody running SOAP on tomcat 3.3.1?
> I'm having a problem setting-up the classpath so that the SOAP engine
> can find the class files that make-up the web service.
> I guess what I really need to know is how to pass a classpath to a
> servlet in tomcat 3.3.1. Thanks.
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Autos - Get free new car price quotes
> http://autos.yahoo.com
> 
> --
> To unsubscribe, e-mail:   <ma...@xml.apache.org>
> For additional commands, e-mail: <ma...@xml.apache.org>
> 


-- 


Cordialement.

======================================================
Carl CABOU
SNCF - Direction de la Recherche et de la Technologie
Pôle Nouvelles Technologies de l'Information
Paris St-Lazare, bureau 295
Tel : 01 53 42 92 34
Poste : 31 92 34
======================================================


--
To unsubscribe, e-mail:   <ma...@xml.apache.org>
For additional commands, e-mail: <ma...@xml.apache.org>


tomcat 3.3.1

Posted by Gordon Easton <go...@yahoo.com>.
Anybody running SOAP on tomcat 3.3.1?
I'm having a problem setting-up the classpath so that the SOAP engine
can find the class files that make-up the web service.
I guess what I really need to know is how to pass a classpath to a
servlet in tomcat 3.3.1. Thanks.


__________________________________________________
Do You Yahoo!?
Yahoo! Autos - Get free new car price quotes
http://autos.yahoo.com

--
To unsubscribe, e-mail:   <ma...@xml.apache.org>
For additional commands, e-mail: <ma...@xml.apache.org>


tomcat 3.3.1

Posted by Gordon Easton <go...@yahoo.com>.
Anybody running SOAP on tomcat 3.3.1?
I'm having a problem setting-up the classpath so that the SOAP engine
can find the class files that make-up the web service.
I guess what I really need to know is how to pass a classpath to a
servlet in tomcat 3.3.1. Thanks.


__________________________________________________
Do You Yahoo!?
Yahoo! Autos - Get free new car price quotes
http://autos.yahoo.com