Book Review: Ruby on Rails Web Mashup Projects

Providing a whistlestop tour through building a range of Ruby on Rails applications on the back of other services, Ruby on Rails Web Mashup Projects is aimed at those who are already comfortable building rails applications and want some sense of how they can be enhanced using a variety of other visualisation, data and processing providers.

Aside: The term ‘mashup’ is one of those tech terms that’s almost impossible to pin down. I should note that the way it used in this book (seemingly any application that draws on a third-party services) is not a way I’d choose to use it, but I’d rather focus on the book itself than on titling semantics.

The book hits all the usual suspects—google maps, flickr, technorati, wikipedia—and also covers the basics of building a facebook application, using paypal for payment processing, and sending faxes and SMS messages through a third party gateway. For those who want a quick overview of all of those options it’ll give you enough to get started, though as a result of the pace only the very basics of each service is covered and anyone wanting to build a sophisticated app will have quite a bit of work in front of them learning the nuances of their chosen service providers.

Along with providing little detail of each service, the book suffers from not really digging into a number of topics that would make it a much more useful companion. Big challenges when building applications dependent on other peoples’ servers include effective testing, caching, surviving third-party service outages, and good ways of integrating your interface code into your application.

Lip service is paid to the need to be prepared for a third-party service outage, but no examples of how to survive are offered. It wouldn’t have been hard to illustrate ways of falling back to local databases or to secondary services, but none is offered. There’s no mention of writing tests, so no opportunity to offer ways to use mocks to test the local code or to discuss how you might automate your testing of the integration itself, and caching is similarly overlooked except in the case of amazon e-commerce services where it is used to preserve historical data that amazon doesn’t make accessible.

The absence of testing really shows through in some of the code offered. Much of the code demonstrated in the book is overly complex and procedural, with little in the way of modular, reusable components. Similarly there’s little by way of discussion of where such code fits into your rails application, with some classes that are clearly models (albeit non-ActiveRecord models) dropped into the lib folder, and numerous very fat controllers.

Rather than covering seven separate projects, this box would have been much stronger had it focussed on two or three, but worked through them in significantly more detail. Possibly there wouldn’t have been a chance to touch on as many services, but by building up one of the more diverse systems like the ticketing application in detail, covering failover, testing, clean integration with a rails app, and other such topics this could have been a much richer book with appeal for a far wider range of developers. As is, it’s worth skimming through if you’re looking for advice on sending faxes or SMS, but won’t help much with the real challenges of building a robust application that’s dependent on third-party services.

Disclaimer: I was sent a copy of this book for review by the publisher. You can find it at packt, amazon US, amazon UK and all sorts of other places.

1 comment

  1. Thanks for review. It is not positive, but really sincere.