thrift-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Commented] (THRIFT-4656) infinite loop in latest PHP library
Date Thu, 01 Nov 2018 23:01:00 GMT


ASF GitHub Bot commented on THRIFT-4656:

sokac commented on issue #1618: THRIFT-4656: Fix infinite loop in PHP TCurlClient
   @jeking3 it was the case before THRIFT-4645 got fixed. If response was empty, an exception
was thrown.
   Alternative is to override readAll. Parent class TTransport,
, will keep calling read until receives all bytes. Since we know TCurlClient won't get any
more bytes, an exception can be thrown in case read returns fewer than $len.
   To give a little bit of background how this issue was reproduced - due to bug in upstream
under some conditions, upstream could respond with 200 OK and empty response. This caused
PHP to spin until supervisor terminated it due reached timeout.
   Do you think this PR makes sense or should we override readAll? I'm open to suggestions

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

> infinite loop in latest PHP library
> -----------------------------------
>                 Key: THRIFT-4656
>                 URL:
>             Project: Thrift
>          Issue Type: Bug
>          Components: PHP - Library
>            Reporter: Josip Sokcevic
>            Priority: Major
>             Fix For: 0.12.0
>         Attachments: 0001-THRIFT-4656-Fix-infinite-loop-in-PHP-TCurlClient.patch
> The latest PHP library can enter into infinite loop state when specific payload is returned:
> HTTP status: 200
> Response body: <empty>
> It was introduced with THRIFT-4645, where check was replaced from
> {code:java}
> !$this->response_{code}
> to
> {code:java}
> $this->response_ === false{code}

This message was sent by Atlassian JIRA

View raw message