Leveraging Agile web technologies to build LinkedIn Polls
February 17, 2011
Code Alert! This is a part of our continuing series on Engineering at LinkedIn. If this isn’t your cup of Java, check back tomorrow for regular LinkedIn programming. In the meanwhile, check out some of our latest product features, tips and tricks, or user stories. - Ed.
We launched a new version of the LinkedIn Polls application towards the end of last year. The new version was a major overhaul from a usability standpoint, making it easier to vote, share, and interact with a poll. Our engineering team’s goals included promoting agility in code development and simplicity of operations in production.
Here’s a showcase of a few of the technologies used to re-build LinkedIn Polls with insight into why we chose to employ them.
Ruby and Rails 3
Ruby is a great language for building business rules. It’s concise, highly readable and perhaps most importantly, it’s fun to program in. Polls uses Rails 3, the latest incarnation of the model-view-controller (MVC) framework for building web applications. Rails gets your web application up and running quickly with reasonable conventions. It’s fun to have an application that you can start showing people in a browser within minutes. Plus, speed of development is a very important aspect to building applications so that we can react quickly to user feedback. our users can tune and tweak.
JRuby and Glassfish
Polls uses the latest versions of the JRuby Ruby interpreter and the Glassfish application server for deployment. JRuby is a fantastic way to leverage an existing Java codebase right in your Rails application. It has saved us countless hours in engineering effort by not having to rewrite Java code in Ruby just to use it in the Polls application. On top of that, it’s very fast and leverages the years of engineering effort put into building the Java Virtual Machine.
Polls uses Raphaël to draw the charts on the results page. On browsers that support it, Rapaël will render the graphs using SVG (Scalable Vector Graphics), and on Internet Explorer, it will render the graphs using VML (Vector Markup Language). It’s a great time saver to write the rendering logic once and not worry about support in the various browsers. Also, the graphics that Raphaël renders are also viewable on Apple’s iOS devices such as the iPad and iPhone.
When code is ready to go into production on Polls, we use Capistrano to manage the deployments right from a developer’s workstation. Capistrano is great for creating reliable deployment recipes that can be customized to a particular application’s topology. Capistrano also helps us make deployments seamless, and we are able to release new code for Polls on a daily basis if necessary.
If you haven’t used it already, give the new LinkedIn Polls a try. And, if you’re a passionate Rails developer who wants to build and launch web scale apps, check out our careers page for open positions.