Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Express.js HTTP request timeout

I was wondering if anyone could tell me what the default HTTP request timeout is when using express.

What I mean by this is: after how many seconds of dealing with a http request will the Express / Node.js server close the connection, when the browser nor server closed the connection manually?

How do I alter this timeout for a single route? I would like to set it to about 15 minutes for a special audio conversion route.

Thanks a lot.

Tom

like image 766
Tom Avatar asked Aug 28 '11 17:08

Tom


1 Answers

req.connection.setTimeout(ms); appears to set the request timeout for a HTTP server in Node.js.

like image 114
Tom Avatar answered Oct 10 '22 20:10

Tom