cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: Determine available upload/download bandwidth

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Thu, 28 Nov 2013 22:35:27 +0100 (CET)

On Tue, 26 Nov 2013, Sandeep Sastry wrote:

> I am looking for suggestions and solutions on determining available
> bandwidth before uploading or downloading.

There's no way and for an application there's no fixed available bandwidth -
ever.

What does available bandwidth mean? At every possible moment in time you can
fire up something else in the background that changes the conditions for your
particular application and gives it more or less than it had the second
before.

Is "available bandwidth" what you managed to transfer 10 seconds ago? What you
managed to use yesterday? If so, then just count that and use in the future.
If it isn't, you need to adjust dynamically for the conditions you get while
doing the transfer. Or let the user set the limits based on some knowledge
about the physical pipe he/she uses.

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2013-11-28