Best practice for AsyncClient usage across multiple unknown hosts #3671
-
|
Hi team 👋 , I have a use case where I need to make HTTP requests to about 10 different hosts, each host will receive many requests, but the hostnames are only known at runtime. Should I use a single Many thanks |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
|
Good question. Using a single client instance everywhere is a sensible approach. It might be that there's smarter policies we could have by default (for a future version) eg. an overall ratelimit perhaps? |
Beta Was this translation helpful? Give feedback.
Just use a single client and assume that's a sensible policy. You'll see timeouts if you're bumping into the limits.