Click here to Skip to main content
13,558,199 members
Click here to Skip to main content
Add your own
alternative version

Tagged as


3 bookmarked
Posted 27 Nov 2011
Licenced CPOL

A comment about using NHibernate

, 27 Nov 2011
Rate this:
Please Sign up or sign in to vote.
A comment about using NHibernate

In this post, Ayende talks about when we should use NHibernate and he points out that in almost any read only scenario, another approach can be preferred. I think he forgot to mention the fact that even in such a scenario, we can leverage a very reliable multi DB abstraction offered by NH that can help us if we think of targeting different data platforms.

According to me, we should say that the point of decision to choose from NH to another approach is the ability to create an entity model, and an entity model helpful to our objectives. This can also depend on how much we are comfortable with the technology. Another interesting extension of the argument is, if we should not use NH, what can we use instead? Well not for sure EF, since the reason of renouncing to NH in a project should be the same to avoid EF. The NOSql solutions work only if we can completely avoid a relational database, and the pure crude ADO.NET is just ugly. An option could be Dapper, a lightweight OR/M (not exactly an OR/M, but almost) that removes all the ugliness of ADO.NET and does not change the performance in comparison on using the manual data access approach. I did not try it myself, but one of its users is stackoverflow, so this should be by itself a guarantee.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

No Biography provided

You may also be interested in...


Comments and Discussions

-- There are no messages in this forum --
Permalink | Advertise | Privacy | Terms of Use | Mobile
Web02-2016 | 2.8.180515.1 | Last Updated 28 Nov 2011
Article Copyright 2011 by Felice Pollano
Everything else Copyright © CodeProject, 1999-2018
Layout: fixed | fluid