Jeremy Mikkola created THRIFT-4845:
--------------------------------------

             Summary: PHP's TCurlClient ignores timeout values smaller that 1 
second
                 Key: THRIFT-4845
                 URL: https://issues.apache.org/jira/browse/THRIFT-4845
             Project: Thrift
          Issue Type: Bug
         Environment: PHP 7.*
            Reporter: Jeremy Mikkola


Presently, if you specify a fractional timeout (e.g. 0.2) with 
setTimeoutSecs(), it is ignored and the request is allowed to take an arbitrary 
amount of time.

 

Specifying integer timeouts works as expected (e.g. 1, 2, or more seconds).

 

This happens because [this 
line|https://github.com/apache/thrift/blob/c9b1e29bc9e0702d7441383358d565e1e76ccea7/lib/php/lib/Transport/TCurlClient.php#L233]
 uses CURLOPT_TIMEOUT instead of CURLOPT_TIMEOUT_MS.

 

I have a patch I'll submit after creating this  ticket.



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

Reply via email to