cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Beryozkin (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CXF-6377) Wrong media type of response
Date Wed, 29 Apr 2015 12:55:06 GMT

    [ https://issues.apache.org/jira/browse/CXF-6377?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14519301#comment-14519301
] 

Sergey Beryozkin commented on CXF-6377:
---------------------------------------

Hi Neal,

I think this test is invalid. It does not make sense to return a media type if a response
entity is absent. 
I'm afraid it needs to be challenged, sorry about it :-)

Sergey



> Wrong media type of response
> ----------------------------
>
>                 Key: CXF-6377
>                 URL: https://issues.apache.org/jira/browse/CXF-6377
>             Project: CXF
>          Issue Type: Bug
>          Components: JAX-RS
>    Affects Versions: 3.0.3
>         Environment: Windows
>            Reporter: Neal Hu
>             Fix For: 3.0.5
>
>
> Resource class
> public Response getMediaType() {
> 		MediaType media = MediaType.APPLICATION_ATOM_XML_TYPE;
> 		Response response = Response.ok().type(media).build();
> 		return response;
> 	}
> get media type from response on client side is  null.
> Spec 3.8 Determining the MediaType of Responses
> 1. If the method returns an instance of Response whose metadata includes the response
media type
> (Mspecified) then set Mselected = Mspecified, finish.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message