Ruby

Ruby is a dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write.

JRuby is an implementation of the Ruby programming language atop the Java Virtual Machine (JVM).

I've been working with Ruby since 2004. Our team at Wordtracker uses Ruby and Ruby on Rails to produce (almost) all of our work. I've used JRuby as a convenient way to deploy work in a Java-centric environment, and to leverage the huge number of existing Java libraries whilst enjoying writing in Ruby.

I'm very happy that one of my posts has been published as a chapter in the JRuby Cookbook by O'Reilly.

Articles on Ruby

  1. How to use context and describe in Rspec

    I've never been super-clear on how to use context and describe in Rspec. A colleague recently clarified it really nicely for me. Context is an English version of what the setup is for that group of specs. The nouns around your specs. Describe is for the verbs (methods) and/or the nouns (objects) which you are testing.

    Read More...

  2. Checking out Puffing Billy

    Puffing Billy gives you the ability to stub out remote sites in your request (integration) specs, in the same way that you'd use Webmock or Artifice in your unit/controller specs. I thought I'd throw a little non-rails spec together to check it out.

    Read More...

  3. Serving Rails apps with Unicorn and Bluepill. Includes Resque.

    At Wordtracker we run four Rails apps in production. Two of those use background jobs with a Resque implementation. We've recently switched to serving them using Unicorn, with Nginx as a proxy. We've found the restart times on deployment to be far quicker and more graceful, which gives us confidence to roll out new features to our customers as soon as they become available.

    Read More

  4. Rsift - A Ruby client for Datasift

    DataSift is a "real time social media filtering engine". They have recently published an API which allows developers to create and manage "streams". The domain of social media curation is very hot right now, so I was very interested to receive a alpha API key to try it out. I work mainly with Ruby, and there wasn't a client out there yet to "wrap" the Datasift API in Ruby, so I thought that writing that gem would be my first step.

    Read More about Rsift

  5. Running background jobs with Resque

    Our users at Wordtracker search for keywords and linking domains many thousands of times each day. We run the majority of these searches as "background jobs" to maintain a good user experience. We'd developed an in-house system written in Ruby and Sinatra for running these jobs, but the robustness and error reporting wasn't as good as we wanted. I decided to take a look at the Redis backed Resque (pron. res-queue |ˈreskyoō|) to see whether it would work well for us.

    Read More

  6. Using Chowder for Simple Rack-based authentication

    I have been searching for some time for a simple rack based authentication system. A key requirement for me is that I'd like it to work with the data storage mechanism of my choice - MongoMapper. I spotted a project on github called Chowder, which worked really nicely...

    Read More

  7. JRuby Cookbook published

    I'm very happy that my contribution to the O'Reilly JRuby Cookbook has been accepted. It is only a little bit on making SOAP calls from Ruby (JRuby) using the Mule ESB Client library, but it is still really nice to see my name inside a book.

    Read More

  8. Calling SOAP Services from JRuby

    I have been working on a project which uses the Mule ESB, and a JRubyOnRails app. Part of this means calling SOAP services from within the JRuby app. Ola Bini sets out a couple of approaches in his JRuby on Rails book,but I thought I would blog the success I've had using the mule-client libraries. I am passing "complex" Java objects around in these SOAP services, not just primitives - always more difficult when it comes to SOAP interoperability.

    Read More