You don't need to monkey patch anything. You can use RestClient::Request
directly, like:
RestClient::Request.execute(:method => :get, :url => url, :timeout => 10, :open_timeout => 10)
But remember the worst case scenario is 20 seconds.
Check the other post answer https://stackoverflow.com/a/5445421/565999
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…