Pre-open tcp connection open with Nodejs and Axios

Viewed 116

I need to send http request at specific time in future. How can I make Axios (or other Nodejs lib) pre-open tcp connection and keep it alive until http request is made?

Purpose of this is to decrease network latency. Because if I start http request from scratch at specified time, it takes a while to establish connection, dns resolve and so on. As result remote server receives my http request too late after desired timestamp.

0 Answers
Related