Win a copy of Machine Learning Systems: Designs that scale this week in the Scala forum
or Xamarin in Action: Creating native cross-platform mobile apps in the Android forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Problem in return Collection in Websphere Webservice  RSS feed

Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I wrote a simple web service which returns Complex user defined objects like CustomerBean/UserBean within a Hash Map.

Here is the webservice:

public class MyWebservice{

public HashMap getData(HashMap requestData) {
//goes and gets the data from business service component and
//gets business objects and it is stored into response HashMap.
HashMap responseData = new HashMap();
responseData.put("customer",new CustomerBean());
return response;

public class CustomerBean implements {
// has attributes and its getter and setter method...

Web service is deployed in IBM Websphere Application Server 6 environment.

When client calls this web service, I am getting an exception at the server:
"Serialization cannot occur for CustomerBean"

Could you please explain what i am doing wrong. How to fix this issue...

I'm so happy! And I wish to make this tiny ad happy too:
Rocket Oven Kickstarter - from the trailboss
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!