This is the mail archive of the
cygwin-apps@cygwin.com
mailing list for the Cygwin project.
Re: multiple mirror code && setup HEAD
- From: "Robert Collins" <robert dot collins at itdomain dot com dot au>
- To: "Gary R. Van Sickle" <g dot r dot vansickle at worldnet dot att dot net>,<cygwin-apps at sources dot redhat dot com>
- Date: Tue, 4 Dec 2001 22:44:25 +1100
- Subject: Re: multiple mirror code && setup HEAD
- References: <NCBBIHCHBLCMLBLOBONKMELKCHAA.g.r.vansickle@worldnet.att.net>
----- Original Message -----
From: "Gary R. Van Sickle" <g.r.vansickle@worldnet.att.net>
> Coolness. One dime-a-dozen-notion that I've been having is an
automatic site
> selection ability that would ping 'em all and let God sort 'em out, or
rather
> qsort, and then fail over in order of increasing ping.
qsort is history :}. The list.h template uses an insertion sort.
I've already though about this:
What you should do is have all the sites pinged when parsing
mirrors.lst, and then store the resulting list and times for future
reference on disk.
Then in the site_list_type_constructor add a ping parameter, and pass it
the ping. It should prepend the stringified ping to the sort key, giving
the user a list of fastest->slowest sites, and meaning that all the
linear code will automagically hit the fastest site first.
Rob