This actually means that server exists and accepts the request, but doesn’t return data, still keeping a connection open. Yes, in a case of such a malicious server the client will hang up.
There is no default timeout in Net::HTTP
. In normal scenario it will receive HTTPRequestTimeOut
response (which server is on duty of.) If you feel there might be any problem, you set the timeout yourself. But sometimes you really need to wait infinitely (server is processing large amount of data and you know it.)
Actually, I’d suggest it’s not a Net::HTTP problem
. Matz has already had problems with rb_wait_for_single_fd calls
. It actually looks like deadlock inside ruby thread synching, not like a server hangup.