Wednesday, March 2, 2011

Book review: Clojure In Action

There are already a few books on Clojure. I decided to go for one of the latest, Clojure In Action (the book was still in early access, finished, but not published yet).

The first seven chapters teach the basics. They are easy to follow. I felt that the chapter on concurrency was not clear enough. A lot of text about common concurrency issues, but no practical examples of the different Clojure features. Maybe in the sections that I skipped ? (more on that next). I just wanted to see one example using multiple threads and Refs, Agents and others.

Leaving the basics, chapter 8 shows how to do mocking and stubbing in unit testing. Then come four chapters using third party libraries and frameworks. I'm ashamed to say that I skipped most of their content (50 pages). HBase, Redis, RabbitMQ, Hadoop... That would have been fine with small libraries which do not require configuration or knowledge. This does not reduce the value of the book though. It's an "In Action" book after all. It is clearly stated on the cover that it will use these frameworks. If you are interested to learn more than just the language, this book contains a vast panorama of "in action" examples. I may come back to these chapters later.

Then, back to the core. Protocols, macros, etc... The modus operandi thing in the Protocols chapter confused me more than anything, although it's a good exercise at making macros.

I haven’t read other books on Clojure so I can’t compare this one to others. I'm pleased with this book, although I was interested only in the core functionality. I think it will give you enough grounding to get going with Clojure.

1 comment: