RSS Feed

RSS
Comments RSS

Episode 2 Transcript – A Festivus for the REST of us!

On Monday, Microsoft released 20,000 lines of source code to the Linux kernel. The move was prompted to improve interoperability between the two operating systems when Windows is acting as a guest OS for Linux. However, on his blog, the Network Plumber’s Journal, Stephen Hemminger noted that prior to the open sourcing of the drivers, those same drivers were actually violating the GPL by mixing closed and open source code.

 

Since the blog post, Microsoft’s Senior Director of Platform Strategy Sam Ramji has responded, said that the reason for the release was the mutual benefit of customers, partners, the community, and Microsoft. Whatever the true reason, acknowledging the GPL is a monumental step forward for Microsoft’s relationship with the Open Source community. Let’s hope to see more of this in the future.

 

Hot on on the heels of other providers, Engine Yard this week launched it’s cloud-based deployment service for Ruby applications. Engine Yard hosts big name Ruby sites such as Github and is best known for being a player at the high end of the market. The cheapest of their new cloud offerings, called the Solo plan, starts at $25 a month plus a charge for how CPU cycles you use. If this type of billing is starting to sound familiar that’s partly because Engine Yard’s offering is built on top of Amazons EC2 platform. So the application hosting market is really hotting up these days – with the likes of Google, Engine Yard and Heroku competing for a slice (no pun intended).

 

One of the big concepts around cloud computing and web apps in general is the services they expose through formats other than web pages. Traditionally this has been done with complicated SOAP web services. But since the rise of frameworks such as Ruby on Rails, a different approach to distributed computing called REST has become popular. This week we’ll take quick look at REST, which stands for Representational State Transfer. REST looks to the HTTP foundations of the web as its inspiration in tackling this issue. The idea behind REST is to think of things on the server that want to expose as individual resources. And then define a small set of operations to interact with that resource. This keeps your API really simple because every resource on your server responds to the same set of actions.

 

In Ruby on Rails, a RESTful resource, such as a user object, exposes only 7 actions. The first 4 of these actions are  create, update, destroy and show and these are the most fundamental to understanding how a RESTful service operates. These actions do exactly what they say on the tin. So, for example if you want to delete a user on the server you would call the destory action on the user resource. And if you wanted to update a users details you’d call the update action on the user resource and pass along with it the details you’d like update. As we mentioned earlier, REST is inspired by HTTP. Well, this becomes apparent when we see that the 4 actions we just mentioned can actually be mapped back to the the HTTP protocol. The create action maps to the HTTP verb called POST. So when we talk about creating a user, we’re really saying that we’ll send a POST request to the server. And this is exactly how a  form in a HTML page achieves same thing. So instead of fighting the web, RESTful services actually work with the HTTP protocol and this means that all the cool stuff that a web server does for you like caching, work out of the box if think RESTfully. The other HTTP verbs used are PUT for updates, DELETE for destroying resources and GET to show a resource – in order words to display a resource.

 

That’s pretty much all for this week. The other interesting piece of news was the that the BBC are releasing an Open Source Javascript library called glow. Glow differentiates itself from other libraries in its level of support for older browsers and the bbc are seeking to build a community around glow – looking for feedback to see what goes into the next version – which will be the 2.0 release.

 

How long will we have to wait before we see Gerry Ryan and Joe Duffy contribute their patches back to the open source community – probably not in time for the 2.0 release…

 

Not included in the transcription: Mentioned the Geeknic going down on the 2nd August 2009 at 1pm in Farmleigh park.