Wednesday, February 25, 2009

Rawr and build times

Rawr 1.3.x introduces a feature where the JRuby jar used in the project is the same jar that's used to compile the app. This way your projects can use different JRuby versions, and your environment's JRuby may also differ.

Unfortunately, the feature was mostly a hack because it needed to be fixed immediately for some of our production projects. It cleverly invokes the JRuby jar's jrubyc script to compile the files... one at a time. This can make compilation take 30 minutes (at least it feels that long) when compiling something with ActiveSupport and friends from a clean slate. I decided that I had traded some speed for stability, and the speed I could fix later. This became too painful once I started testing out some build bugs I was getting on Windows, so I fixed it.

Rawr now makes the same build in about 30 seconds from a clean state. That's a drastic improvement! I'd like to also visit some of the Java compiling to see what I can do to speed that up, since I know we compile one Java class at a time.

I'm not ready to publish these features yet, since I actually have regressed on a few of our other features.

0 comments:

Post a Comment