Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ


Choose your language

InfoQ Homepage News Rich Hickey on Clojure's Features and Implementation

Rich Hickey on Clojure's Features and Implementation

This item in japanese


In this interview taped at QCon London 2009 Rich Hickey talks about Clojure, shortly before the 1.0 release.

The interview covers many of the interesting aspects of Clojure, particularly its support for concurrency. Rich explains Clojure's model of Software Transactional Memory (STM), which uses the concept of Multiversion concurrency control (MVCC).
But STM is only one way to use concurrency; Clojure also supports many other concurrency primitives, such as Agents (not to be confused with Actors - the difference is explained in the interview).
Next to the existing concurrency primitives, Rich also explains his ideas for a new one, which will make it easier to use Locks, maybe allowing to define acquisition order or other properties.

Developers familiar with mainstream OOP languages and interested in Clojure will be particularly interested in Clojure's programming model. Clojure supports Java's OOP model and can interact seamlessly with Java libraries and OOP concepts. Idiomatic Clojure code, however, doesn't rely on the OOP concepts of languages like Java or C#. Runtime polymorphism is achieved through multimethods which is integrated with the Java class system, but can be made much more flexible with custom dispatch methods. The interview discusses the reasons behind and advantages of this approach in detail.

Finally, the discussion also touches the topic of performance. Clojure compiles to Java bytecodes and also has advantages over other dynamic languages, in that it allows to avoid polymorphism when it's not needed. It also allows arithmetic to be as fast as normal Java code (ie. written in the Java language), as long as certain rules are obeyed.

InfoQ has covered Clojure previously, a good overview of many aspects of the system is Rich's talk at the JVM Summit 2008.

Watch "Rich Hickey on Clojure".

Rate this Article


Hello stranger!

You need to Register an InfoQ account or or login to post comments. But there's so much more behind being registered.

Get the most out of the InfoQ experience.

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Community comments

  • (great 'stuff)

    by Gresham Paul,

    Your message is awaiting moderation. Thank you for participating in the discussion.

    Thanks Rich & Werner. For me, Clojure is the most exciting technology out there today. Exciting in itself, but I also can't wait to see what people do with it (are able to do with it). It's certainly the first viable alternative for moving 'hard' problems off of common lisp and the rich libraries of Java are definitely attractive. Would have liked some information on performance of multi-dimensional arrays (an Achilles heel for Java).

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p

Allowed html: a,b,br,blockquote,i,li,pre,u,ul,p