Closed Bost closed 3 years ago
You need to set the timeouts explicitly. The default value 0
is to block indefinitely:
:connection-timeout
:socket-timeout
See the documented examples in the README: https://github.com/dakrone/clj-http#get
I've been testing your advice for a while and it looks like it helps. Thanks, I'm closing this issue.
Glad to hear :)
I execute two parallel requests from Heroku using
(get url {:accept :json :debug true})
. Sometimes, one of them - the one againsthttp://covid-tracker-us.herokuapp.com/all
never ends. I get neither an exception nor any timeout nor anything else. The other one - againsthttps://covid.ourworldindata.org/data/owid-covid-data.json
runs always fine. Can you tell me please, am I doing anything wrong? ThanksIf you need to see more, here my get-json function