How to queue http get requests in Nodejs in order to control their rate?

前端 未结 3 1205
后悔当初
后悔当初 2021-02-20 16:27

I have a NodeJS app which sends HTTP get requests from various places in the code, some are even dependent (sending a request, waiting for a reply, processing it and based on re

3条回答
  •  [愿得一人]
    2021-02-20 16:35

    The Async module has a number of control flow options that could help you. queue sounds like a good fit, where you can limit concurrency.

提交回复
热议问题