Johnny's Software Saloon

Weblog where I discuss things that really interest me. Things like Java software development, Ruby, Ruby on Rails, Macintosh software, Cocoa, Eclipse IDE, OOP, content management, XML technologies, CSS and XSLT document styling, artificial intelligence, standard document formats, and cool non-computing technologies.

My Photo
Name:
Location: Germantown, Maryland, United States

I like writing software, listening to music (mostly country and rock but a little of everything), walking around outside, reading (when I have the time), relaxing in front of my TV watching my TiVo, playing with my cat, and riding around in my hybrid gas/electric car.

Wednesday, April 26, 2006

Bundles in Locomotive - now available for Rails 1.1

At last! There are now Ruby On Rails 1.1 bundles for Locomotive Ruby development on the Mac!!

Anyone who does Ruby On Rails development on Mac OS X is no doubt aware of Ryan Raaum's Locomotive open source project.


Locomotive creates a little pocket universe on your Mac. In it you can run any version of Ruby, Ruby On Rails, and certain Ruby libraries that you want alongside the standard Ruby libraries.

Ryan uses a special trick with something Mac programmers call a bundle. Within a bundle, a framework found within the bundle will supercede those installed in the System and User Library.

This is a nice way to solve, or literally sidestep, most versioning problems that would otherwise exist on the Mac. Or, for that matter, any computing platform.


It is a wicked-cool solution to the age old software configuration problem I refer to as version torsion stress. I had to give it a name because it is a force in so many real-world software development antipatterns.

Think of it as an Indian burn you get from software versions that don't want to work together in the same system.

Some libraries want too work with an older library. But other libraries want to deal with a newer library. And you are trying to deal with this all in the same system in the same server. You need to give each application its own environment. Or at least give certain applications different versions of certain libraries than other applications.

With a tool like Ryan's you can do that. Thanks to his brain's and the power of the Mac's architecture.
Bundles in Locomotive

So thanks to Ryan, it is easy for us guys using Macs to develop Ruby On Rails 1.1 applications, while still supporting any old Rails 1.0 applications.

It occurs to me that some hosting companies could really use the power of the Mac frameworks+bundles dichotomy to provide some really cool virtual environments to their customers. Mac OS X might have a real edge over other operating systems used by these server hosting companies.

Now that Go Daddy! has become the first giant web hosting company to offer Ruby On Rails hosting services, interest in this premium capability might develop at one of these companies.

A lot of customers of some other web hosting companies were pleased when Rails 1.1 came out. Unfortunately, they were horrified when their web apps broke when their hosting company thew a master switch and switched all Rails apps for all their customers at once from Rails 1.0 to Rails 1.1.

For one thing, the customers would no doubt have prefered to do that change themselves after some testing and perhaps some program modifications or library version changes.

For another thing, the environment that was configured system-wide on those machines was not too well tested

Using the Locomotive solution, configurations of the new Rails 1.1 environment could have been set up alongside the Rails 1.0 environment that was already in production.

After it was tested, that environment could be left in situ on the server(s). Customers could have switched over to that environment when they felt ready to do so. Without migrating to a different server or lots of other disruptive alternatives.

I have long thought that Apple Computer should be a hosting company - not just for static media like web pages and photos, songs, and movies - but for processes, programs, and services. Maybe they will do something cool like that when their gargantuan server facility in Newark, NJ comes online sometime this year or next.

The success of this bundles+frameworks trick in Locomotive - and the problems recently cited with shared servers at various hosting companies - convinces me that now is the time for Apple to step forward and try it out.

They might find yet another niche they are uniquely suited for in the always evolving computer industry.

0 Comments:

Post a Comment

<< Home

Related pages & news