Upgrade to Pro — share decks privately, control downloads, hide ads and more …

speed of cpan module installation

speed of cpan module installation

Gotanda.pm #5 2015/06/24

Shoichi Kaji

June 24, 2015
Tweet

More Decks by Shoichi Kaji

Other Decks in Technology

Transcript

  1. contens • installation of cpan modules • speed is important

    • what can I do? • demo • conclusion
  2. installation of cpan modules • all you have to do

    is to type: • cpanm Module • How easy!
  3. But

  4. speed is important • If you develop a perl project,

    it is common to depends on hundreds of cpan modules • Then bootstrapping time is >10minutes • This is A PROBLEM!
  5. What can I do? • In QA Hackathon 2015 at

    Berlin, miyagawa developed cpanm2.0 “menlo”, which will be released a “regular” perl module. • OK, let’s use menlo in parallel!
  6. Acme::CPAN::Installer • With cpanfile.snapshot, 
 install cpan distributions in parallel.

    • [EXPERIMENTAL]
 With the assumption that dependencies are statically determined,
 resolve distributions name and
 install them in parallel.
  7. result > ls cpanfile cpanfile.snapshot > cat cpanfile requires ‘Plack’;

    > time carton install … real 0m33.857s > time cpan-installer … real 0m13.344s #### 33sec => 13sec! ####
  8. conclusion • cpanm is nice • we can use it

    as a module • If we install cpan modules in parallel, 
 then we see speed improvement! • I propose that cpan module dependencies must be statically determined.