elarson’s posterous

 
« Back to blog

Rails Got Racked!

Ok, that title is terrible... But as Sam mentioned, Rails has adopted Rack! I've managed to avoid Ruby in favor of a superior language (which I type with my tongue firmly in my cheek), but when I did use Ruby and Rails, Rack was of definite interest. Of course, my understanding of Rack came from direct exposure to WSGI. The big difference between the two is that Rack is effectively an API at the object level, whereas WSGI is really at the langauage level. This distinction is primarily because Python has functions as first class objects, which allows passing callables around. This should be familiar to anyone using Javascript who has passed a function to an event handler or ajax call. The WSGI pattern is effectively the same. Since I haven't used Rack outside of basic experiements, I don't know how the idea of middleware translates. My guess is that it could be somewhat optimized in a similar fashion that tools are optimized in CherryPy.

Wild and inaccurate assumptions aside, WSGI has been a huge factor in the growth and development of the Python web development landscape. I can only imagine that it might help promote similar evolution within the Ruby community.

Loading mentions Retweet