-- fix read timeout handling in TSocket
authorAditya Agarwal <aditya@apache.org>
Wed, 23 May 2007 02:14:58 +0000 (02:14 +0000)
committerAditya Agarwal <aditya@apache.org>
Wed, 23 May 2007 02:14:58 +0000 (02:14 +0000)
commite04475b5aaa2bba920a2c1b4021a1a447f947dd9
tree3d1a40d17e951eb8ee56748ba955873beb8a08e3
parent3a3b53bc6eefa91ea60e5da2b2c91519ca1d9b2e
-- fix read timeout handling in TSocket

Summary:
- turns out that EAGAIN can be returned both when there is a transmission timeout and when there
  is a lack of system resources.

This diff has a hacky fix for respecting a user specified read timeout.

Reviewed By: Steve Grimm, Marc, Slee

Test Plan:
- Tested by trying to crash an srp machine

Revert Plan: No.

Notes:
- Also added functionality to allow users to specify the max number of recv retries (in the case
  when EAGAIN is returned due to a lack of system resources)

git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665121 13f79535-47bb-0310-9956-ffa450edef68
lib/cpp/src/concurrency/Exception.h
lib/cpp/src/transport/TSocket.cpp
lib/cpp/src/transport/TSocket.h