Node.js versions should be preloaded

m.goleb's Avatar


23 Jun, 2014 04:28 PM

Currently testing on Node.js versions different than the default one (now 0.10.28) is far from ideal; it requires slow uninstallation and installation of the separate Node version like in:
which is extremely slow. AppVeyor should have Node versions preloaded and available without manual installation, like Travis does.

  1. Support Staff 1 Posted by Feodor Fitsner on 24 Jun, 2014 03:37 AM

    Feodor Fitsner's Avatar

    How many releases would we need - the latest 0.8.x, 0.10.x and 0.11.x - three in total? Or more?

  2. 2 Posted by m.goleb on 25 Jun, 2014 09:06 PM

    m.goleb's Avatar

    Travis preloads a lot of Node versions and that would be nice but I'd be happy even if just latest patch versions of each Node release were available here; so yes, three in total (and four once 0.12 is released)

    Travis uses nvm for that: Perhaps you could use which is its adaptation to Windows? (I haven't tested that, though).

  3. Support Staff 3 Posted by Feodor Fitsner on 25 Jun, 2014 09:22 PM

    Feodor Fitsner's Avatar

    I see. Looking at nvmw code - it downloads node.exe, then unpacks it. Well, I think we could have a faster approach - I'll let you know when it's ready for testing.

    - Feodor

  4. 4 Posted by m.goleb on 25 Jun, 2014 09:27 PM

    m.goleb's Avatar

    Travis uses nvm in a way that they do a lot of:
    nvm install 0.10.26
    nvm install 0.10.27
    etc. before freezing the VM. Then on the actual run they read the node_js field and do:
    nvm use THAT_FIELD
    so the actual switching is blazing fast and all VMs can still be the same.

    Obviously, you can preload Node versions however you want, I just linked to a prepared approach.

  5. Support Staff 5 Posted by Feodor Fitsner on 25 Jun, 2014 09:30 PM

    Feodor Fitsner's Avatar

    Yeah, you're right. Thanks!

    - Feodor

  6. 6 Posted by m.goleb on 26 Jun, 2014 08:09 AM

    m.goleb's Avatar

    Hm, actually, Travis does load only latest patch versions of Node.js (not sure if always or if they keep the previous one as well etc.); see:

    I don't even think we need 0.6.

  7. 7 Posted by m.goleb on 26 Jun, 2014 08:11 AM

    m.goleb's Avatar

    See e.g. this run:
    A month ago they had:
    - 0.6.21 - 0.8.23, 0.8.25, 0.8.26 - 0.10.18 0.10.25 - 0.11.11

  8. Support Staff 8 Posted by Feodor Fitsner on 26 Jun, 2014 02:34 PM

    Feodor Fitsner's Avatar

    Yeah, I see.

    - Feodor

  9. 9 Posted by m.goleb on 29 Dec, 2014 02:20 PM

    m.goleb's Avatar


    did you manage to make any progress on the issue? With recent Travis speed ups ( the slowness of AppVeyor runs when the needed Node versions is different than the preloaded one is really jarring; it often doubles the test time, sometimes even triples.

  10. Support Staff 10 Posted by Feodor Fitsner on 29 Dec, 2014 06:27 PM

    Feodor Fitsner's Avatar

    There is a faster way to switch node.js:

    Install-Product node [x86|x64]

    However, the latest available node.js version on build workers is 0.10.32. We are going to add recent ones in the coming week.

    Regarding containers - when it comes to Windows we'll be supporting that for sure. Though I believe our Hyper-V based environment has comparable performance. It's just open-source that currently runs on Azure, but this might change in the future.

  11. 11 Posted by m.goleb on 29 Dec, 2014 06:34 PM

    m.goleb's Avatar

    Most projects will need to test on at least two different Node.js minor versions. The patch level itself is not *that* important (obviously within reason, it's good to have a recent patch) but many people need at least 0.8, 0.10 and 0.11. Once 0.12 comes out, it can replace 0.11 pre-release versions.

    I test most of my Node modules on 0.10 and 0.11 so I feel the slowness in the 0.11 case; see e.g.:

  12. Support Staff 12 Posted by Feodor Fitsner on 29 Dec, 2014 07:03 PM

    Feodor Fitsner's Avatar

    Cool, then replace Update-NodeJsInstallation (Get-NodeJsLatestBuild $env:nodejs_version) with Install-Product node $env:nodejs_version to speedup 0.11 job. Look at the example:

  13. 13 Posted by m.goleb on 01 Jan, 2015 06:33 PM

    m.goleb's Avatar

    Thanks a lot, that speeds up the build a lot!

    One question - are all these commands as well as Node versions available via this command documented anywhere? I couldn't find it.

  14. Support Staff 14 Posted by Feodor Fitsner on 02 Jan, 2015 12:03 AM

    Feodor Fitsner's Avatar

    There is a note here:
    Maybe not the best place and it deserves a separate article.

  15. 15 Posted by m.goleb on 02 Jan, 2015 01:35 PM

    m.goleb's Avatar

    Thanks! The thread can be closed now. :)

  16. m.goleb closed this discussion on 02 Jan, 2015 01:35 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac