How to handle Http request timeout


I have a flow CheckFileAndGetData that handles the file check and retrieves the data of the file, this flow is called by the flow DataCollect by http nodes.

In the case of a large number of files, about 10,000 files, the error time out Server is not responding at node ★★★ with the information as below:

Error: ESOCKETTIMEDOUT : http://localhost:1880/CheckFileAndGetData

In Node-red, is it possible to set the timeout time for http node?
Or is there a way to handle the timeout in this case, please tell me!

Any hint will be great.

From the http request node help info

If set to a positive number of milliseconds, will override the globally set httpRequestTimeout parameter.

1 Like

Set msg.requestTimeout (use a change node or function node before the http request)


@E1cid , @Steve-Mcl Thank you for your support!
My Node-RED version is v0.20.7 so the http request node doesn't have requestTimeout option.
I have found http-request-ucg node with httpRequestTimeout option but it doesn't seem to be working as expected.
Also, since the number of data files is not known, setting the timeout value does not completely solve the problem, so I am thinking of another way.

1 Like

Your NodeRed is very old.
Just try to make update (and flow backup before)

1 Like

I get it. Thank you!

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.