What is the difference between timeout and timeout?

In a Ruby RestClient gem, what's the difference between a timeout and an open-timeout function?

http://www.ruby-doc.org/gems/docs/w/wgibbs-rest-client-1.0.5/RestClient/Resource.html#method-i-open_timeout

I did not get anything from the doc file of this gem.

+6
source share
1 answer

You are reading the wrong documentation (yours for wgibbs-rest-client , which has not been updated since 2009): here is the correct one . But this does not say anything about the difference, although it is simple:

:open_timeout is the timeout for opening a connection. This is useful if you are calling servers with slow or shaky response times.

:timeout is the timeout for reading the response. This is useful to make sure that you don’t get stuck halfway while reading or are not stuck by reading a 5 MB file when you expect 5 KB of JSON .

+11
source

All Articles