Java

Waiting for my Ruby Gems Bulk Update

One of the huge pains in the ass when using CRuby (MRI) RubyGems is that if you haven’t updated your gems in a while you can easily send your machine into a spin when you innocently type sudo gem update.

The message:

Bulk updating Gem source index

appears and then you just sit there… for hours… while gem… tries to parse… the yaml… which is obviously… much faster… than streaming… XML.

JRuby doesn’t seem to have the same issues, presumably something to do with the implementation not being so memory hungry.

Anyway if you are having this problem too you’ll be glad to know that a happy ending is possible via use of the –bulk-threshold parameter. Simply use a command line like the following and your low resource system will not actually process in chunks rather locking up your swap memory.

sudo gem update --bulk-threshold 10009
Standard