I wish they mentioned performance a bit more. From my personal experiences and almost every benchmark I've ever seen clojure struggles and seems laborious to optimize unless you have a lot of experience with it. I guess it might be comparable to ruby, so it didn't affect them. In my brief use of clojure, the language was very simple and the docs were very easy to use.
We'd already written PuppetDB in Clojure a while ago, and thus have several years' experience with the language. It's been fast enough and practical enough for our needs, and a pleasure to use. This is not a knock against Scala, which is also a great language.
The article didn't mention anything about performance really (except the JVM itself). And besides that what makes you think that Clojure doesn't have good performance?
They're abandoning Ruby because its performance is shit so yeah, performance is the big factor here. Now what I'm saying is that you're rewriting shit because you need performance and you're picking the JVM, why not rewrite it in Scala?
The programming language we chose for PuppetDB is Clojure, and we’ve been moving towards adopting Clojure for most of our new back-end projects.
I'm assuming they took a look at Scala, didn't like it, like Clojure as a language, and Clojure performance is within their performance requirements. They can always dip down into Java anyway if they need to squeeze out some more performance.
It doesn't seem like they are rewriting stuff, but rather picking up Clojure for new projects. It's a ruby shop, so speed is probably not a big concern for them in the first place.
But not JRuby. I'd be curious to know what made them decide to go with Closure rather than JRuby, especially given that Puppet is primarily a Ruby shop.
Which points to some issue in the Ruby object/dispatch model that causes this slowness. Can't blame JRuby's performance on GC or threads in the case of JRuby.
16
u/strattonbrazil Apr 13 '14
I wish they mentioned performance a bit more. From my personal experiences and almost every benchmark I've ever seen clojure struggles and seems laborious to optimize unless you have a lot of experience with it. I guess it might be comparable to ruby, so it didn't affect them. In my brief use of clojure, the language was very simple and the docs were very easy to use.