You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Josip Sokcevic (JIRA)" <ji...@apache.org> on 2018/09/20 18:39:00 UTC

[jira] [Updated] (THRIFT-4641) TCurlClient doesn't check for HTTP status code

     [ https://issues.apache.org/jira/browse/THRIFT-4641?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Josip Sokcevic updated THRIFT-4641:
-----------------------------------
    Summary: TCurlClient doesn't check for HTTP status code  (was: TCurlTransport doesn't check for HTTP status code)

> TCurlClient doesn't check for HTTP status code
> ----------------------------------------------
>
>                 Key: THRIFT-4641
>                 URL: https://issues.apache.org/jira/browse/THRIFT-4641
>             Project: Thrift
>          Issue Type: Bug
>          Components: PHP - Library
>    Affects Versions: 0.11.0
>            Reporter: Josip Sokcevic
>            Priority: Major
>             Fix For: 0.12.0
>
>
> TCurlTransport doesn't check for HTTP status code. Other languages, such as Go and Java do check for it. This can lead to potentially wrong exception being thrown: TProtocolException instead of TTransportException. To be more precise, TCurlTransport doesn't error out and Protocol starts to parse response, which may lead to TProtocolException. For example, AWS ALB may return 502 Bad Gateway with HTML as part of payload when there's an issue with an upstream. In such case, a client may want to retry but it only makes sense if there's a transport exception.



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