aspose file tools
The moose likes Web Services and the fly likes WSDL confusion Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Web Services
Reply Bookmark "WSDL confusion" Watch "WSDL confusion" New topic
Author

WSDL confusion

Chinmay Bajikar
Ranch Hand

Joined: Dec 08, 2001
Posts: 159
Hi,

I have a simple web service operation which returns a string. This was working fine for me.
Recently I needed to change the return type from String to a List(ArrayList).
I duly generated the new wsdl and a new client and tried to invoke the newly deployed
web service.
But it gives me an AXIS fault.
I checked the newly generated WSDL and the response element now shows the type as
"xsd:anytype".
Does this have anything to do with the axis fault that I am getting?

Thanks,
Chinmay.


The strength of the Wolf is the pack & the strength of the pack is the wolf....Rudyard Kipling
Rizwan Mohammad
Ranch Hand

Joined: Sep 02, 2005
Posts: 445
I think using List,Vector may not be compatible with many other systems. I had similar problem. Try using String array instead of List and check whether your solve your problem.


Rizwan
SCJA, SCJP, SCWCD, SCBCD, SCDJWS.
Jeroen T Wenting
Ranch Hand

Joined: Apr 21, 2006
Posts: 1847
You will indeed need to return an array instead of an ArrayList, and define that returntype in the WSDL something like this.



and use that as the returntype for your wsdl:message


42
Chinmay Bajikar
Ranch Hand

Joined: Dec 08, 2001
Posts: 159
Hi,
Thanks ...that String[] thing worked.
I dont need to change the wsdl, since it is properly generated
by the java2wsdl in Axis2 1.1

I tried to have a 2d String[], but that didnt work.
The wsdl generated was still the one which represented the 1d String[].
Maybe this is stuff for the axis2 guys to look into.

Thanks a lot for the suggestions,
Chinmay
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: WSDL confusion
 
Similar Threads
Webservices + Jrun
my webservice supports Axis1.x but not Axis2.x ,so is it the compatibility issue?
Axis 1.4 does not validate input parameters?
Axis1 error: Could not generate WSDL!
my webservice supports Axis1.x but not Axis2.x ,so is it the compatibility issue?