On Wed, Jan 29, 2014 at 8:55 AM, <[email protected]> wrote: > Updated Branches: > refs/heads/1986-fix-ibrowse-infinite-async-timeout [created] b35884580 > > > ibrowse: fix async hang due to infinite timeout > > - import upstream timeout fix[1] > - addresses COUCHDB-1986 and quite possibly COUCHDB-1874 as well > > [1]: https://github.com/cmullaparthi/ibrowse/pull/91.patch > > > Project: http://git-wip-us.apache.org/repos/asf/couchdb/repo > Commit: http://git-wip-us.apache.org/repos/asf/couchdb/commit/b3588458 > Tree: http://git-wip-us.apache.org/repos/asf/couchdb/tree/b3588458 > Diff: http://git-wip-us.apache.org/repos/asf/couchdb/diff/b3588458 > > Branch: refs/heads/1986-fix-ibrowse-infinite-async-timeout > Commit: b35884580436824adc7f250d9adbe857440026d7 > Parents: 5c9f9a9 > Author: Dave Cottlehuber <[email protected]> > Authored: Wed Jan 29 07:29:35 2014 +0100 > Committer: Dave Cottlehuber <[email protected]> > Committed: Wed Jan 29 08:28:34 2014 +0100 > > ---------------------------------------------------------------------- > src/ibrowse/ibrowse_http_client.erl | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > ---------------------------------------------------------------------- > > > > http://git-wip-us.apache.org/repos/asf/couchdb/blob/b3588458/src/ibrowse/ibrowse_http_client.erl > ---------------------------------------------------------------------- > diff --git a/src/ibrowse/ibrowse_http_client.erl > b/src/ibrowse/ibrowse_http_client.erl > index a1cf6eb..0ba5e97 100644 > --- a/src/ibrowse/ibrowse_http_client.erl > +++ b/src/ibrowse/ibrowse_http_client.erl > @@ -226,12 +226,12 @@ handle_info({ssl_error, _Sock, Reason}, State) -> > {stop, normal, State}; > > handle_info({req_timedout, From}, State) -> > - case lists:keymember(From, #request.from, > queue:to_list(State#state.reqs)) of > + case lists:keysearch(From, #request.from, > queue:to_list(State#state.reqs)) of > false -> > {noreply, State}; > - true -> > + {value, #request{stream_to = StreamTo, req_id = ReqId}} -> > + catch StreamTo ! {ibrowse_async_response_timeout, ReqId}, > shutting_down(State), > -%% do_error_reply(State, req_timedout), > {stop, normal, State} > end; > > >
+1 for the patch. I can't be sure it is actually fixing COUCHDB-1986 since the problem was already solved for me. Btw why not upgrading to the latest upstream release and port the socks5 patch to it? - benoit
