couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fdman...@apache.org
Subject svn commit: r1138973 - /couchdb/trunk/src/couchdb/couch_api_wrap_httpc.erl
Date Thu, 23 Jun 2011 16:37:37 GMT
Author: fdmanana
Date: Thu Jun 23 16:37:37 2011
New Revision: 1138973

URL: http://svn.apache.org/viewvc?rev=1138973&view=rev
Log:
Fix pull replications hanging due to missing ibrowse error

Again, don't always rely on ibrowse to send us an error message
signalling a connection timeout.

Modified:
    couchdb/trunk/src/couchdb/couch_api_wrap_httpc.erl

Modified: couchdb/trunk/src/couchdb/couch_api_wrap_httpc.erl
URL: http://svn.apache.org/viewvc/couchdb/trunk/src/couchdb/couch_api_wrap_httpc.erl?rev=1138973&r1=1138972&r2=1138973&view=diff
==============================================================================
--- couchdb/trunk/src/couchdb/couch_api_wrap_httpc.erl (original)
+++ couchdb/trunk/src/couchdb/couch_api_wrap_httpc.erl Thu Jun 23 16:37:37 2011
@@ -155,6 +155,11 @@ process_stream_response(ReqId, Worker, H
         end;
     {ibrowse_async_response, ReqId, {error, _} = Error} ->
         maybe_retry(Error, Worker, HttpDb, Params, Callback)
+    after HttpDb#httpdb.timeout + 500 ->
+        % Note: ibrowse should always reply with timeouts, but this doesn't
+        % seem to be always true when there's a very high rate of requests
+        % and many open connections.
+        maybe_retry(timeout, Worker, HttpDb, Params, Callback)
     end.
 
 



Mime
View raw message