Book review: NHibernate in Action
Writing this book review feels kind of weird because it hasn’t actually hit the shelves yet. It is accessible however through the Manning Early Access Program. This book provides a clear insight of using NHibernate as the data access layer of your applications and beyond.
The excessive amount of NHibernate features isn’t the only thing that is written down. There is also a good coverage of OO principles and Domain-Driven Design, although it isn’t the primary objective of the book of course. This is especially true for the first and the last three chapters. If you’ve already read the nominal books DDD and you are familiar with Persistence Ignorance, then you can safely skim through these chapters unless you want to see the interpretation of the authors when it comes to these principles. If you are new to these concepts, then these chapters are of great value to wet your appetite.
Although this book covers a lot of ground, I would certainly recommend it when you’re rather new to NHibernate and ORM’s in general. I guess this still includes me, although I’ve been using NHibernate for quite some time now. If you already have some experience with NHibernate, then this book probably doesn’t teach you that much. Still, it can quickly get you up to speed when you want to use a particular feature that you haven’t used before.
The only minor thing about this book is that I’m afraid that it will soon be out-of-date. The book only covers NHibernate 1.2.x and no features from the upcoming 2.0 release, which adds a lot of new and interesting features. It would be nice if the book already covered some of these features as most of them are ported from Hibernate itself, which is the original Java version.
On the other hand, this book provides an in-depth view of the basic features of NHibernate, which aren’t necessarily going to change that much over time anyway.
Let me round off this post by saying that I’m really impressed by the list of books that Manning is going to release the next couple of months. These are the ones that I’m particularly interested in:
- Building Domain Specific Languages in Boo
- ASP.NET MVC in Action
- Brownfield Application Development in .NET
- IronRuby in Action
I already bought LINQ in Action and also read a lot of good things about C# in Depth, which I’m going to pick up soon.
Take care.
Filed under: Esoterica





Hi there
Thanks for the (early) review! I joined as co-author of the book last year, and although much of the book had been written already, it’s been a fun journey!
It’s interesting to hear first thoughts on the book, and I think your summary was very close to my own thoughts.
There *is* quite a lot of coverage of surrounding principles (domain modelling, layered architecture etc), and I think we struggled to know where to stop there. Like you say, it wets the appetite and is a good introduction. We do recommend that people to go off and get the books dedicated to those periphery subjects if they’re interested.
I too thought it was a shame we didn’t cover the latest 2.0 stuff, it was just a problem of time and it’s Alpha status unfortunately.
On the plus side, the book continues to teach me new tricks as I visit and re-visit various chapters. There’s some great stuff on caching, persistence lifecycle and performance that is really helpful to both the new and slightly more seasoned NHibernate developer!
Manning are rocking at the moment - they’ve done some great books. “C# in Depth” arrived the other day and it’s very good so far. I also can’t wait to read LINQ in Action, I met Fabrice (the author) at TechEd and he’s a great, and very clever guy!
This looks like an interesting blog, am adding to my RSS
Thanks again.
Tobin
[...] Book Review: NHibernate in Action (Jan Van Ryswyck) [...]
@ Tobin: I think that covering OO, DDD, layering is one of the strenghts of the book, seeing NHibernate in the bigger picture. You are right that the nominal works should be read too (I should have made tham ore clear in my blog post).
Anyway, the book helped us tremendously during the implementation of our first sprint with NHibernate and still guides us through the features of NHibernate. I highly appreciate the work and efforts you and your colleagues have spend on writing it.
I hope that it will be a huge hit on Amazon
Jan
Cheers for the kind words, Jan
It’s truly *great* to hear you’ve got value from the book - makes the late-night writing sessions and stress all worth it
Many thanks again
Tobin
Just ordered the book through the MEAP. The PDF isn’t the pretty formatted version for publishing (I would assume that is coming soon), but it will do. I’ve usually found the Manning books to be high quality, so I have decent expectations for this one (I’ve only read 1 chapter so far). It’s unfortunate that timing occurred as it did and that some of the new features of 2.0 are not in the book. I don’t know too much about nHibernate, so I don’t know how much of a problem that will be.
I guess what concerns me the most about using software libraries like nHibernate and Castle Project is that it seems like it’s one or two guys working on stuff in their spare time and updates and bug fixes are done… “when they are done” (there is no set release schedule, and the author’s primary job obviously takes precedence). Also the documentation doesn’t compare to the wealth of documentation and coverage that the Microsoft framework libraries and add-ons (LINQ to SQL, EF, ASP.NET MVC, etc) get. Microsoft just has a ton of internal people writing stuff, and a lot of people outside of Microsoft are also writing about these new technologies.
I guess those are problems that OS has always had, and are not going anywhere soon.
Oh well, I’m excited and interested in finishing the book. I also am participating in the ASP.NET MVC, Javascript for Ninjas (always wanted to be a ninja as a kid!), and ASP.NET Brownfield Development MEAP books. I’m a big fan of Manning (I have at least 10 or more softcover books and a few PDF books) and a long time ago I did some work as a technical editor on Fergal Grime’s .NET book for Manning.
@Eric: I can asure you that when it comes to NHibernate and the Castle Project, that it’s not just a couple of guys that work on this product. For the 2.0 release of NHibernate, they are actually working with sprints of 15 days (check this post: http://groups.google.com.ar/group/nhibernate-development/browse_thread/thread/b999120f95bdd70a). These guys are moving mountains of work!
Not all projects get this much attention and indeed most of them have just a couple of maintainers. You can always step up to the plate and participate or even donate. If there is a lack of documentation, then by donating the developers can start looking at that.
For me the strongest point in using OS projects like Castle and NHibernate is their strong communities. There are several user groups with a lot of interesting stuff to learn:
http://groups.google.be/group/nhusers?hl=nl
http://groups.google.be/group/castle-project-users?hl=nl
I hope you enjoy the book as well as I have
[...] Castle Windsor and NHibernate with WCF - Throwing the WCF facility and some Rhino Tools in the mixBook review: NHibernate in ActionUsing Entity-Assigned ID’s Possibly related posts: (automatically generated)Milla Jovovich [...]
[...] Castle Windsor and NHibernate with WCF - Throwing the WCF facility and some Rhino Tools in the mix Book review: NHibernate in Action Using Entity-Assigned ID’s Share: These icons link to social bookmarking sites where [...]