Quantcast
Channel: Active questions tagged rest - Stack Overflow
Viewing all articles
Browse latest Browse all 3663

How to prevent time out on a long-running HTTP request?

$
0
0

I have an API that executes a potentially long-running task that can take up to 10 minutes. This works fine when I hit the API from Postman, but when I use the API from a browser (Chrome, Safari, Firefox) the request times out before a response is received.

The API is written in NodeJS/Express, and I have already increased the server's timeout. I have also increased the timeout on the JavaScript library I use to make the API call (request-promise). The API continues running and completes even after the request has timed out in the browser. How can I stop the request from timing out through the browser?


Viewing all articles
Browse latest Browse all 3663

Trending Articles