curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: curl: add --rate to set max request rate per time unit

From: Daniel Stenberg via curl-users <curl-users_at_lists.haxx.se>
Date: Mon, 4 Apr 2022 15:49:57 +0200 (CEST)

On Mon, 4 Apr 2022, Paul Gilmartin via curl-users wrote:

> I might prefer to simplify to:
> curl --delay 0.07 $URL[a-z] -O # Always in seconds

That's simpler for your specific use case, sure, but not for the rather common
use case when you know want to allow N requests per M and you don't know how
long time each transfer is going to take.

I'm under the impression that most servers that implement rate limiting do
that per request (start of transfer really), not with a required specific
silent period between two requests.

In your case above, if that's a 70 millisecond delay between the transfers and
maybe the transfers took let's say 130 milliseconds on average, that means max
5 transfers/second. So maybe that frequency should be maintained even if the
transfers gradually go faster (or slower) ?

-- 
  / daniel.haxx.se
  | Commercial curl support up to 24x7 is available!
  | Private help, bug fixes, support, ports, new features
  | https://curl.se/support.html
-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-users
Etiquette:   https://curl.haxx.se/mail/etiquette.html
Received on 2022-04-04