I would like to have a simple sample NH project that you would consider best practice that people could refer to when getting started with N开发者_JAVA技巧H?
I've been using it for a couple of months now and still struggle with the numerous ways there are to do things but not knowing which is the best approach to follow.
I think one of the best samples is sharp architecture. You can find Northwind example there.
Also you can look at Best practices on code project
uNhAddIns also contains some excellent samples.
Effectus is also interesting.
Still, I'll have to agree with Darin Dimitrov. There's no such things as "best" practices; there are many ways to do things and each one has its pros and cons.
Personally, I learned quite a bit from the WhoCanHelpMe application, which provides a nice reference implementation of the S#arp Architecture framework.
In addition to this, a wealth of information can be found on the following blogs which belong to NHibernate contributors:
- Ayende
- Fabio Maulo
- Davy Brion
I think that really depends on what you mean by best approach. You may like watching some dimecasts screencasts on the subject, I have found them very informative. There are also loads of other topics too. Dimecasts.net
http://www.summerofnhibernate.com/ is a great screencast series on NHibernate
Code Camp Server is a nice reference for ASP.NET MVC and NHibernate http://codecampserver.codeplex.com/
Also, read a book on the subjects. It will help you a long way.
Edit: You seem to be looking for a general guide, to take you through some concepts of good design etc. Specifically for ASP.NET MVC, I can recommend http://jeffreypalermo.com/blog/read-all-of-asp-net-mvc-2-in-action-now-while-you-wait-for-the-printed-book/
You mention Onion architecture, the book was written by Jeffrey Palermo, who (AFAIK) invented the term.
If you'd like more sample projects (there are lots and lots) of ASP.NET MVC (with or without NH), let me know.
精彩评论