Look out – this post is going to be a bit dry.
Over the Thanksgiving weekend, I upgraded Ravelry from a crusty old nearly-2.0 version of Edge Rails to the latest 2.2.2. Other people’s upgrade war stories were really helpful so I figured that I’d post my own. (See also gusg.us’s 2.2 story, assaydepot’s 2.1 story)
Here are the things that had to be fixed or tweaked:
- I moved a bunch of stuff out of here into the config/initializers directory. Much neater. I also config.gem‘d my gems.
- cache_fu plugin
- Broken. Upgrading to the latest source from github made it all better.
- memcached gem
- I use Evan Weaver’s juiced up memcached client. Upgrading to the latest source from github made it all better.
- xss_terminate plugin
- I’m using xss_terminate for sanitizing input and I needed to add a little patch to an initializer to make the plugin work properly: http://code.google.com/p/xssterminate/issues/detail?id=3#c0
- exception_notification plugin
- Wasn’t working right, but I’m using HopToad now so I just trashed it.
- I read that weird stuff would happen with older acts_as_versioned and the new dirty attributes/partial updates. Upgraded to the latest source. Unfortunately, the newer version seems to handle version columns differently. I was previously using “acts_as_versioned :version_column => ‘lock_version'” to base the “version” column in the versioned table off of the model’s “lock_version”. Now it wants both to be called “lock_version”. I just patched it for now.
- RFPDF plugin
- Broken. Changed init.rb from ActionView::Base::register_template_handler 'rfpdf', RFPDF::View to ActionView::Template::register_template_handler 'rfpdf', RFPDF::View
- rails_asset_id in ActionView::Helpers::AssetTagHelper
- Gone. Reworked some helper code – I didn’t need it anyway.
- Broken by ActiveRecord changes. Here is the fix: http://ar-code.lighthouseapp.com/projects/35/tickets/25-edge-callback-overrides-inconsistently-pass-arguments
- More small breakage. Here is the fix: http://github.com/valda/active_form…
- has_many_polymorphs plugin
- Oh god – has_many_polymorphs was a nightmare (as expected). I upgraded to the latest and then had to fix broken stuff for a while. I don’t know what version I was using before but stuff changed. ack.
That’s it! Also, HopToad was a great help in finding a few small bugs and glitches once I pushed the upgraded version out to production.
I’m going to go back to fun Ravelry-improving work for a while. Still, I’d like to move to Git. …and maybe take the latest JRuby out for a test-drive. The total amount of memory that our Mongrels (Thins) consume is pretty embarrassing and things are heating up in the JRuby world with faster releases, a more threadsafe Rails, and so on…
Toolbox photo from Flickr/mamabarns .