big-r81 commented on issue #5802:
URL: https://github.com/apache/couchdb/issues/5802#issuecomment-3603753398

   I played a little bit in `stop_client_process_if_disconnected`, but I'm not 
sure if its the right place ...
   
   ```diff
   stop_client_process_if_disconnected(Pid, ClientReq) ->
       case mochiweb_request:is_closed(ClientReq) of
           true ->
               exit(Pid, {shutdown, client_disconnected}),
               couch_stats:increment_counter([couchdb, httpd, 
abandoned_streaming_requests]),
   +           couch_stats:decrement_counter([couchdb, httpd, 
clients_requesting_changes]),
               ok;
           false ->
               ok;
           undefined ->
               % Treat unsupported OS-es (ex. Windows) as `not closed`
               % so we default to the previous behavior.
               ok
       end.
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to