You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Vladimir Bogatyrov (JIRA)" <ji...@apache.org> on 2018/04/20 12:22:00 UTC

[jira] [Commented] (CXF-7720) Header values are lost

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

Vladimir Bogatyrov commented on CXF-7720:
-----------------------------------------

Normally, HttpURLConnection object from which the headers are read at https://github.com/apache/cxf/blob/master/rt/transports/http/src/main/java/org/apache/cxf/transport/http/Headers.java#L292 contains one map entry for all the header values.

When the issue is reproduced however, HttpURLConnection object contains a separate entry for each of the headers with the similar name but with different cases, which leads to the situation when only one header value gets into headers map and all the other values are lost.

> Header values are lost 
> -----------------------
>
>                 Key: CXF-7720
>                 URL: https://issues.apache.org/jira/browse/CXF-7720
>             Project: CXF
>          Issue Type: Bug
>          Components: Transports
>    Affects Versions: 3.2.4
>         Environment: Windows 7
> Java 1.8.0_152
> SoapUI 5.2.1
>            Reporter: Vladimir Bogatyrov
>            Priority: Major
>         Attachments: consumer.zip, rest_mock_provider_soapui_project.xml
>
>
> When a request is made by WebClient to a service that returns several headers of the same name but with different cases, e.g.: 
> "Set-Cookie" with value "aaa"
>  "set-cookie" with value "bbb"
>  "SET-COOKIE" with value "ccc"
> then the response object contains only one header value, all other values are lost.
> The issue  is not reproducible in all cases, but only with some service providers and is probably caused by low-level details of provider implementation. 
>  
> In the attachment there is a SoapUI REST mock service and CXF WebClient-based consumer with which the issue is reproducible.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)