You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@falcon.apache.org by Balu Vellanki <ba...@hortonworks.com> on 2014/07/18 03:47:40 UTC

RestAPI response - can we move to MediaType.APPLICATION_JSON?

Hello Team,

What are the use cases or reasoning behind  supporting and maintaining
MediaType.TEXT_XML, MediaType.TEXT_PLAIN, MediaType.APPLICATION_JSON
responses for RestAPIs. Can we move away from XML responses and just
support JSON response. This would make marshalling and unmarshalling easier.

Thanks
Balu

-- 
CONFIDENTIALITY NOTICE
NOTICE: This message is intended for the use of the individual or entity to 
which it is addressed and may contain information that is confidential, 
privileged and exempt from disclosure under applicable law. If the reader 
of this message is not the intended recipient, you are hereby notified that 
any printing, copying, dissemination, distribution, disclosure or 
forwarding of this communication is strictly prohibited. If you have 
received this communication in error, please contact the sender immediately 
and delete it from your system. Thank You.

RE: RestAPI response - can we move to MediaType.APPLICATION_JSON?

Posted by Srikanth Sundarrajan <sr...@hotmail.com>.
Hi Balu,    We aren't doing anything in particular to support an additional mime type besides adding the annotation. Jersey is doing that for us.
RegardsSrikanth Sundarrajan

> Date: Wed, 23 Jul 2014 14:45:18 -0700
> Subject: Re: RestAPI response - can we move to MediaType.APPLICATION_JSON?
> From: balu@hortonworks.com
> To: dev@falcon.incubator.apache.org
> 
> Hi Srikanth
> 
> Sorry for the delayed response. There are no issues currently in supporting
> the mime types. I want to understand if there is a compelling reason for
> supporting XML and JSON. If not,  going forward we can spend fewer
> resources by supporting  XML or JSON. The consumer of API can easily
> convert from JSON to XML or vice-versa if needed. My experience has been
> that JSON is simpler to produce and maintain.
> 
> Thanks
> Balu Vellanki
> 
> 
> 
> On Thu, Jul 17, 2014 at 11:18 PM, Srikanth Sundarrajan <sr...@hotmail.com>
> wrote:
> 
> > Hi Balu, are there issues in the rest Apis supporting all the mime types?
> >
> > Sent from my iPhone
> >
> > > On 18-Jul-2014, at 7:18 am, "Balu Vellanki" <ba...@hortonworks.com>
> > wrote:
> > >
> > > Hello Team,
> > >
> > > What are the use cases or reasoning behind  supporting and maintaining
> > > MediaType.TEXT_XML, MediaType.TEXT_PLAIN, MediaType.APPLICATION_JSON
> > > responses for RestAPIs. Can we move away from XML responses and just
> > > support JSON response. This would make marshalling and unmarshalling
> > easier.
> > >
> > > Thanks
> > > Balu
> > >
> > > --
> > > CONFIDENTIALITY NOTICE
> > > NOTICE: This message is intended for the use of the individual or entity
> > to
> > > which it is addressed and may contain information that is confidential,
> > > privileged and exempt from disclosure under applicable law. If the reader
> > > of this message is not the intended recipient, you are hereby notified
> > that
> > > any printing, copying, dissemination, distribution, disclosure or
> > > forwarding of this communication is strictly prohibited. If you have
> > > received this communication in error, please contact the sender
> > immediately
> > > and delete it from your system. Thank You.
> >
> 
> -- 
> CONFIDENTIALITY NOTICE
> NOTICE: This message is intended for the use of the individual or entity to 
> which it is addressed and may contain information that is confidential, 
> privileged and exempt from disclosure under applicable law. If the reader 
> of this message is not the intended recipient, you are hereby notified that 
> any printing, copying, dissemination, distribution, disclosure or 
> forwarding of this communication is strictly prohibited. If you have 
> received this communication in error, please contact the sender immediately 
> and delete it from your system. Thank You.
 		 	   		  

Re: RestAPI response - can we move to MediaType.APPLICATION_JSON?

Posted by Balu Vellanki <ba...@hortonworks.com>.
Hi Srikanth

Sorry for the delayed response. There are no issues currently in supporting
the mime types. I want to understand if there is a compelling reason for
supporting XML and JSON. If not,  going forward we can spend fewer
resources by supporting  XML or JSON. The consumer of API can easily
convert from JSON to XML or vice-versa if needed. My experience has been
that JSON is simpler to produce and maintain.

Thanks
Balu Vellanki



On Thu, Jul 17, 2014 at 11:18 PM, Srikanth Sundarrajan <sr...@hotmail.com>
wrote:

> Hi Balu, are there issues in the rest Apis supporting all the mime types?
>
> Sent from my iPhone
>
> > On 18-Jul-2014, at 7:18 am, "Balu Vellanki" <ba...@hortonworks.com>
> wrote:
> >
> > Hello Team,
> >
> > What are the use cases or reasoning behind  supporting and maintaining
> > MediaType.TEXT_XML, MediaType.TEXT_PLAIN, MediaType.APPLICATION_JSON
> > responses for RestAPIs. Can we move away from XML responses and just
> > support JSON response. This would make marshalling and unmarshalling
> easier.
> >
> > Thanks
> > Balu
> >
> > --
> > CONFIDENTIALITY NOTICE
> > NOTICE: This message is intended for the use of the individual or entity
> to
> > which it is addressed and may contain information that is confidential,
> > privileged and exempt from disclosure under applicable law. If the reader
> > of this message is not the intended recipient, you are hereby notified
> that
> > any printing, copying, dissemination, distribution, disclosure or
> > forwarding of this communication is strictly prohibited. If you have
> > received this communication in error, please contact the sender
> immediately
> > and delete it from your system. Thank You.
>

-- 
CONFIDENTIALITY NOTICE
NOTICE: This message is intended for the use of the individual or entity to 
which it is addressed and may contain information that is confidential, 
privileged and exempt from disclosure under applicable law. If the reader 
of this message is not the intended recipient, you are hereby notified that 
any printing, copying, dissemination, distribution, disclosure or 
forwarding of this communication is strictly prohibited. If you have 
received this communication in error, please contact the sender immediately 
and delete it from your system. Thank You.

Re: RestAPI response - can we move to MediaType.APPLICATION_JSON?

Posted by Srikanth Sundarrajan <sr...@hotmail.com>.
Hi Balu, are there issues in the rest Apis supporting all the mime types?

Sent from my iPhone

> On 18-Jul-2014, at 7:18 am, "Balu Vellanki" <ba...@hortonworks.com> wrote:
> 
> Hello Team,
> 
> What are the use cases or reasoning behind  supporting and maintaining
> MediaType.TEXT_XML, MediaType.TEXT_PLAIN, MediaType.APPLICATION_JSON
> responses for RestAPIs. Can we move away from XML responses and just
> support JSON response. This would make marshalling and unmarshalling easier.
> 
> Thanks
> Balu
> 
> -- 
> CONFIDENTIALITY NOTICE
> NOTICE: This message is intended for the use of the individual or entity to 
> which it is addressed and may contain information that is confidential, 
> privileged and exempt from disclosure under applicable law. If the reader 
> of this message is not the intended recipient, you are hereby notified that 
> any printing, copying, dissemination, distribution, disclosure or 
> forwarding of this communication is strictly prohibited. If you have 
> received this communication in error, please contact the sender immediately 
> and delete it from your system. Thank You.