jump to navigation

Webservice: Returning Polymorphic types in response and reference client implementation October 9, 2015

Posted by javafoo in java, webservice.
Tags: , ,
trackback

First let me get this off my chest. You have this fabulous rest service that works flawlessly, sure everything works in SOAP UI. But do you have a reference client implementation, do you eat your own dog food.

Currently working with this other team that we need to integrate with. They have a rest service that has polymorphic types in the response and there is no type differentiator in the json string. We are running into all sorts of unmarshaling issues because of this. Switched out different JSONProviders (Jackson/Jettison), still no luck. Sure there are ways to get around it, custom adapters, deserialzers whatnot. But figuring out how to plug them in can be a pain with scant documentation and when you are doing 2 week sprints. We are a java shop and asked them if they have a reference client implementation in java, since they are too and they said no, but everything works in SOAP UI and for our 1 client that uses dot net.

Please don’t do this to your customers. Atleast have a reference client implementation and don’t do polymorphic types in responses, atleast not without type differentiators.

Comments»

1. hortensejimenez814 - April 9, 2016

Congrats on finishing your sweater, it looks great. And that surprise wool is gorgeous! Click http://s.intmainreturn0.com/hukcoo091645


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: