Send 1 mln requests - strategy

https://lemmy.world/post/8957850

Send 1 mln requests - strategy - Lemmy.World

One needs to send 1 mln HTTP requests concurrently, in batches, and read the responses. No more than 100 requests at a time. Which way will it be better, recommended, idiomatic? * 1) Send 100 ones, wait for them to finish, send another 100, wait for them to finish… and so on * 2) Send 100 ones. And then keep adding new ones into the pool as requests in the pool finish. “Done - add a new one. Done - add a new one”.

This is to me an question lacking very precise requirements. But you say you need batches, so it sounds like option one (batches) is the only option that satisfies the “batches” requirement.
Then this questin isn’t for you.
Nor is the answer for you it would seem.
No, it isn’t