re-frame-http-fx-alpha icon indicating copy to clipboard operation
re-frame-http-fx-alpha copied to clipboard

Handling nesting timeouts

Open danielcompton opened this issue 5 years ago • 0 comments

When I'm making HTTP requests, I have several levels of timeouts I'd like to be able to compose:

  • Granular connection and response timeouts (unfortunately not exposed in Fetch)
  • HTTP Request level timeouts - timeout for a single HTTP request
  • re-frame HTTP request deadline - cumulative time spent attempting to send this logical request, perhaps spread over multiple attempts, and including any exponential backoff time.

I would like to be able to specify an overall deadline for a request after which is it aborted (say 30s), set a per request timeout of 20s, and specify a retry policy. At the moment, it looks like I'd need to build in my own retry logic to handle the overall deadline. Would that be a useful general feature to have?

danielcompton avatar Aug 13 '19 23:08 danielcompton