NCommon
NCommon

One of the changes I made to NCommon in 1.1 was to provide an easy way to configure NCommon’s various services. The approach taken was inspired by MassTransit’s and Caliburn’s configuration API. To configure NCommon you can use the static Configure class:     1 /// <summary>     2 /// Static configuration class that allows configuration of NCommon services.     3 /// </summary>     4 public static class Configure     5 {     6     /// <summary>     7     /// Entry point to...


It’s been a while since my last update on NCommon, and a few features and some bug fixes have been checked in. A lot of new functionality and bug fixes were added with the help of some good feedback from the CodePlex discussions forum. The first change is that the GetCurrentUnitOfWork method in the RepositoryBase class has been made virtual. This is done to allow overriding the default behavior in your implementation of repository that sub-classes RepositoryBase. The reason behind this change is to make RepositoryBase more adaptable to scenarios where a the default behavior needs to be overriden....


Oren’s recent posts on the Repository pattern and ORM have raised a hornets nest and intense discussion on the pattern itself. You can read them @: Repository is the new singleton, Mocking NHiberante and The DAL should go all the way to UI. In this post I’ll give my 2 cents on the points made in Oren’s post. Lets start with the post: Repository is the new singleton. Now I had a very similar discussion with Oren a few weeks back and judging by the comments in that post my reaction was quite similar. I have had some time...


This is part of a continuing series of posts on Fluent NHiberate. Using Fluent NHibernate in Rhinestone – Part I In this part I’ll show how you can map custom user types using Fluent NHibernate. In a previous post I had discussed the need to use custom user types in Rhinestone and had ended with a promise to have a follow up post on the details on implementing the custom user type and provide mappings for using that custom user type in NHibernate....


I’ve been thinking about providing a reference application for NCommon and started to work on the NCommonSampleWebsite currently up at CodePlex when I realized I already had a project that I could use as a reference application for NCommon. It’s been a while since I’ve touched Rhinestone so I will be dusting off the cobwebs on that project and re-focus on finishing Rhinestone as reference DDD web application.


One of the additions to NCommon I haven’t blogged about yet is an implementation of a fetching strategy in NCommon First a brief background on Lazy / Deferred Loading: Most ORM’s provide a concept called lazy loading of related entities. The concept of lazy loading should be well known but if you’re unfamiliar with it here’s a brief overview. Lazy loading, a.k.a deferred loading, is the concept of loading associated entities from the database at the time of access. Meaning that say you have an Order object that has a list of OrderItem entities that represent...


Since my last post on the NCommon project, I’ve been looking at using NCommon as the base framework for Rhinestone. Jumping back into Rhinestone I realized that I first need an implementation of RepositoryBase and UnitOfWork for NHibernate. I decided to go ahead and create implementations of RepositoryBase and UnitOfWork for NHibernate, Linq To SQL and Entity Framework (that last one giving me the most head ache). While developing these implementations, some changes were made to NCommon. Here are some of the changes. Save on IRepository changed to Add and Update ...