This is the mail archive of the cygwin-apps@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: multiple mirror code && setup HEAD


----- 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



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]