I am trying to use ruby rest-client to upload a large number of images to a site that I\'m writing. My code looks like:
RestClient.post url, :timeout => 9000
Looking at the docs, you can pass -1 through RestClient.execute timeout param:
# * :timeout and :open_timeout passing in -1 will disable the timeout by setting the corresponding net timeout values to nil
It can be used as follows:
resource = RestClient::Resource.new(
"url",
:timeout => -1,
:open_timeout => -1
response = resource.get :params => {}