NHibernate in Action Book

NHibernate in Action

I finally had the chance to read the long-waited NHibernate in Action, and I must say I am not very excited about it.

Covering just NHibernate 1.2, the book is, of course, extremely outdated. It does not cover any of the new features, and, what's worse, it does not cover well some of the old features, for example, there is no HQL reference, which I think it's a shame, although it is somewhat referred in chapter 7, nor there is a reference to some other projects, such as NHibernate Validator.

What matters is that if a developer wants to use NHibernate 2.x in a new project, he/she will find the information in this book inaccurate and misleading - NHibernate now supports SQL Server's TIMESTAMP data type for optimistic concurrency, for example, there is the NHibernate Burrow project to support long conversations, NHibernate Validator for validations, there is support for TransactionScope, <many-to-any> mappings, query-only properties, multi-queries, to name just a few.

The book does a fair job in introducing NHibernate, but I sincerely don't like the organization of it.

                             

4 Comments

  • I have to agree wholeheartedly

  • Hi there, I'm one of the authors of NHibernate in Action. Thanks for posting the review, even the bad ones are appreciated :)

    Sorry to hear the book disappointed you. The book contains a boat load of good knowledge, but I also accept we missed the mark in a few places, as you pointed out.

    The biggest sore point was NHibernate 2.x coverage. As you may know, the book was running late already (I think it was supposed to be released in 2007 or something!), and supporting 2.x would have have added yet another year onto the project just to update existing writing, cover new features, get it proof read etc. Annoying that we couldn't do it :(

    The book does have some great points too though :) I've seen seasoned NHibernate users re-think their approach after reading the book. It really can help folks make the most of NHibernate; helping them understand the fundamentals or persistence lifecycle , session usage, identity, caching etc. That stuff really helps with NHibernate 2.x also.

    Drat! You noticed the organisation problems :( We put tons of time into this but yeah, it still needs work.

    Would be really helpful if could explain which areas of HQL you'd like to see covered better? I'll put it on the list for 2nd edition.

    I genuinely think the book covers querying very well; there's about 50 pages with tons of examples and explanations. Let me know what's missing!

    Finally, about Validator/Burrow etc. Yeah, I'd love to see this stuff covered. Fluent NHibernate also. Again, it was out of scope for the first edition and those libraries were rather volatile when writing began, I believe. We'll be looking at some of this for the 2nd edition.

    Thanks again

    Tobin Harris

  • I'm working with NHibernate and reading the book these days, and I have to say I learn a lot from it, I guess it's a good ORM primer and covers ORM basics - mapping, object scope/state, sessions/conversations, caching etc.
    however, after finishing it I would love to read a more up to date book, both for the NHibernate 2.x delta, and for the external projects (I'm also considering using Burrow, fluent NHibernate and Validator).
    any recommendations? is there a date for an updated version?
    and Tobin - if you ever read this - any chance of some bargain for people who purchased the original book - to get a soft copy of the new book?

  • Hi, Tobin, nice to meet you!

    Don't get me wrong; basically, the book is outdated, there are lots of new technologies around NHibernate, and it would be great to see them covered - I am looking forward for the second edition. I would like to see some more HQL covered (functions, complex queries, etc) and also some more advanced ICriteria concepts. Also, some introduction to DDD would be welcome and how it can be done with NHibernate.

    Thanks,

    Ricardo

Add a Comment

As it will appear on the website

Not displayed

Your website