Heads up: Ruby's Net::HTTP silently retries a failing request

Posted . Visible to the public.

Ruby's Net::HTTP library repeats a failing request once Show archive.org snapshot , as long as it deems it idempotent (GET, HEAD etc). Both requests will use the configured timeout. Hence, if both requests time out, Net::HTTP will only return after twice the configured timeout.

This can become an issue if you rely on the timeout to strike precisely.

Dominik Schöler
Last edit
Dominik Schöler
License
Source code in this card is licensed under the MIT License.
Posted by Dominik Schöler to makandra dev (2020-03-26 13:04)