Index
Elsewhere
Navigation
« Appleby vs Hacker - Ooh, yeah. Run, don't walk. | Main | Smart and funny... some people just make you sick »
Thursday
Jul092009

Jack Cough : Scala Over Ruby - His Debate Ends - Mine Meanders Conclusion-ward

Jack Cough on Software: Scala over Ruby - My Debate Ends: This article struck a chord with me today.



I spent most of today flipping back and forward between Ruby and Scala. I'm working on a project where I'm writing some Ruby talking over sockets and streams and files and I needed something JVM flavoured on the other end.

The JVM end was just some driver code that was going in the bin. I had IDEA open because I was using it to write the Ruby side ( at which it is fantastic ) and a simple Scala script seemed easiest - that's where my head has been recently so it seemed most natural.

Things did not go so well - the embedded Ruby that I was using was badly mangled and had chunks of the standard libraries missing. I ended up spending the day bashing away at various ways of solving the problem. With each change of direction I had to rework both the Ruby and the Scala side of the solution. I noticed something odd.

Version 1.0 was a bit faster to write on the Ruby side. I'm a better Ruby programmer than I am a Scala programmer, but that aside I feel that it was slightly easier to express the problem than in Scala. But as the day went on the Scala code became easier to work with whilst the Ruby code had good and bad patches. Significant refactorings or changes of approach often led to runtime errors in the Ruby code. This wasn't a problem in the Scala code. The IDE, compiler and type system caught most of the problems well before I got the application running.

Have I abandoned Ruby forever? No, it is near and dear to my heart and it is still better for bashing out scripts for which there will be no version 2. The benefits of Scala didn't become apparent until 4 to 6 hours into the piece.

Some questions come to mind:

How well would the Scala fare long term? I don't know. It is possible that I won't understand it tomorrow and that every day will have a 4 to 6 hour ramp up time. But I don't think so. I think I'd reap more benefits tomorrow than I did today.

How would Java have fared? I worked on a similar problem the day before and I used Java. It was a pain in the patooty in many ways, but I'm not sure if it comes above or below the Ruby version though. Many of the same characteristics that Scala has were apparent in that session too. I am sure that I found the Scala experiment more productive - despite the fact that I'm a much, much better Java programmer than I am a Scala or Ruby programmer.

References (8)

References allow you to track sources for this article, as well as articles that were written in response to this article.
  • Response
    comfortable fabric whether you want to portable or crossbody is the good choice that only oversize light grey canvas holdall, leisure simple style is your weekend
  • Response
    Rob Lally : Robert Lally : Renaissance Technologist - Blog - Jack Cough : Scala Over Ruby - His Debate Ends - Mine Meanders Conclusion-ward
  • Response
    NFL is seriously one of the largest sports in America. It has a main following.
  • Response
    A man's wallet can add up to an inch of further padding on 1 aspect of your body. This additional inch tends to make your whole physique uneven any time you sit there for leading to your again, to come to be misaligned. Again discomfort in a great number of cases ...
  • Response
    Response: web hosts
    Rob Lally : Robert Lally : Renaissance Technologist - Blog - Jack Cough : Scala Over Ruby - His Debate Ends - Mine Meanders Conclusion-ward
  • Response
    Response: useless
    Rob Lally : Robert Lally : Renaissance Technologist - Blog - Jack Cough : Scala Over Ruby - His Debate Ends - Mine Meanders Conclusion-ward
  • Response
    Rob Lally : Robert Lally : Renaissance Technologist - Blog - Jack Cough : Scala Over Ruby - His Debate Ends - Mine Meanders Conclusion-ward
  • Response
    Rob Lally : Robert Lally : Renaissance Technologist - Blog - Jack Cough : Scala Over Ruby - His Debate Ends - Mine Meanders Conclusion-ward

Reader Comments

There are no comments for this journal entry. To create a new comment, use the form below.

PostPost a New Comment

Enter your information below to add a new comment.

My response is on my own website »
Author Email (optional):
Author URL (optional):
Post:
 
All HTML will be escaped. Hyperlinks will be created for URLs automatically.