From: Tom Hughes Date: Sun, 29 May 2022 09:54:39 +0000 (+0100) Subject: Set a timeout on HTTP requests made by the server X-Git-Tag: live~1184 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/eea25bd1546a42b783ffffb4d0c794d59e643597 Set a timeout on HTTP requests made by the server --- diff --git a/lib/osm.rb b/lib/osm.rb index 73513c3ad..4241ad700 100644 --- a/lib/osm.rb +++ b/lib/osm.rb @@ -520,7 +520,7 @@ module OSM # Return the HTTP client to use def self.http_client - @http_client ||= Faraday.new + @http_client ||= Faraday.new(:request => { :timeout => 15 }) end # Return the MaxMindDB database handle