Hi folks:
I've been reading the docs and tutorials at Apache and trying to make the Apache/Tomcat-centric instructions work in WSAD. Here's what I have so far.
I have all the Axis jar files installed in my project.I have a bean written that accesses my data and returns an object which I defined.That bean also has an "Is Alive" method that just returns the string "I am Alive!"I have a client written that accesses my beanI've changed the name of my bean from abc.java to abc.jws and put it into the WebContent directory So I call my bean's IsAlive method with my client and I see the proper output back at the client.
If I call the method that returns an object instead of just a String then I can see that the call occurs on the server, the data is properly retrieved, the object is created and it tries to return that object. But on the client I see this error :
Exception in thread "main" AxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: org.xml.sax.SAXParseException: Document root element is missing.
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace: org.xml.sax.SAXParseException: Document r
oot element is missing.
at org.apache.crimson.parser.Parser2.fatal(Parser2.java:3182)
at org.apache.crimson.parser.Parser2.fatal(Parser2.java:3170)
and so on.
If I call this URL:
http://localhost:9080/rates/WebRatesService.jws?wsdl I can see that Axis is properly defining the wsdl for that object. The full object is defined with all the sub objects etc.
I expect that I need to take that wsdl file and put it somewhere where my client can find it so it can properly decode the data stream. AM I on the right track? I seem to be stumped at this point.
If it helps then this is how my client is calling the service:
Thank you in advance for any help or advice you may have.
Greg
[edit]
I should add that the TCP monitor shows that while the message went into the web service, the only thing that came out was this:
HTTP/1.1 200 OK
Server: WebSphere Application Server/5.0
Set-Cookie: JSESSIONID=00000S0FL1JQCBR0MFSVKCJVGCQ:-1;Path=/
Cache-Control: no-cache="set-cookie,set-cookie2"
Expires: Thu, 01 Dec 1994 16:00:00 GMT
Content-Language: en-US
Content-Length: 0
Connection: close
So the object is not being marshalled into XML. That must be why there's no root element. No elements came back.
Any ideas why Axis isn't returning the object? Thank you.
[ August 08, 2003: Message edited by: Greg Brouelette ]