@aengelberg this is kind of a late reply, but there should be a default timeout, and it should never hang indefinitely
I see there’s a default connection-timeout
of 60000.0, but I don’t see a default request-timeout
.
I’m not sure what phase of my request hung.
I see
it would be weird for a connection to be open for hours, usually something in between has an idle timeout
I will note that I've seen issues in Netty where connections close, and the notification isn't fired
I don’t know if this issue will ever happen again. I already changed my code to (deref (http/get ...) 30000 ::timeout)
as miikka suggested, just in case.
I've never been able to figure out how to reliably make it happen
sure, that will definitely work
in other Netty codebases I've added periodic checks to see if a connection is closed even though the event didn't fire
I should probably do the same in Aleph, even though I've tried to avoid any sort of background tasks so far
My code is issuing thousands of paginated HTTP requests to load a bunch of data from a Campaign Monitor API, and pretty regularly, at least one request fails for a variety of reasons.
gotcha
well, your workaround is sound, so this probably isn't a concern to you anymore
I wrapped it with retry/backoff logic, but when the deref hung forever, my wrapper couldn’t do anything.
though as always, targeting the latest Netty is always a decent idea, there are lots of fixes each release
thanks.
glad you endorse my duct tape solution.
I might use manifold.deferred/timeout!
, but same difference
The only real potential concern is that maybe I’ll leak a connection object if I don’t wait for it to complete.
But I doubt that issue will happen enough times (if at all) to make any impact.