Lately, I’ve been working improving the CPAN.pm user experience, particularly with regards to configuration. I’ve already made CPAN.pm autoconfiguration quieter, and now I’m working on letting it automatically choose mirrors for you. Here’s sample output from my work in progress:
cpan[3]> o conf init urllist Now you need to choose your CPAN mirror sites. You can let me pick mirrors for you, you can select them from a list or you can enter them by hand. Would you like me to automatically choose the best CPAN mirror sites for you? (This means connecting to the Internet and could take a couple minutes) [yes] Searching for the best CPAN mirrors (please be patient) ............................................................................................................. done! New urllist http://mirror.datapipe.net/CPAN/ http://cpan-du.viaverio.com/ http://cpan.mirror.facebook.net/ http://mirrors.24-7-solutions.net/pub/CPAN/ http://cpan.belfry.net/ commit: wrote '/home/david/.cpan/CPAN/MyConfig.pm'
When I’m done, I hope that a novice Perl programmer can be downloading from CPAN within a couple minutes of running the CPAN client for the first time.
4 Comments
What is wrong with the http://ftp.cpan.org redirector that automatically sends you to a geographically close mirror?
Geographically close doesn’t always mean close in terms of network speed. And while the auto-selection at the moment just uses ping times, I’d like to expand it to include both throughput and mirror freshness. http://ftp.cpan.org gives you no control and no ability to avoid a bad mirror that you frequently get redirected to. This sets some good defaults and then gives control back to you.
That is awesome. That is a very tedious process and to have it automated is great.
Just googled “best cpan mirrors”, because the list is simply too long and I don’t know which ones are best off the top of my head. I think what you are doing is a great idea. I am sure you thinking of this, but just in case I want to mention, I think it’s important to consider mirror update frequency as well. Some mirrors are slow at updating.