-
My current Repository interface looks something like this: public interface IRepository { T FindOne<T>( int id); T FindBy<T>(Expression<Func<T, bool >> expression); IEnumerable<T> FindAllBy<T>(Expression<Func<T, bool >> expression); IEnumerable<T>...
-
Recently, I’ve been entrenched in migrating our existing hbm.xml mapping files to Fluent NHibernate. Having been through other OSS upgrades, I was expecting something along the lines of pulling teeth. I pictured a branch, tedious work to try and move mappings over, all the while making parallel...
-
Today the third part of my series on NHibernate and Fluent NHibernate went live. You can read it here . Summary In part 3 of this article series about NHibernate and Fluent NHibernate I have discussed how to let Fluent NHibernate automatically map a domain model to a data model. We have realized that...
-
A while ago I was having issues using configuring fluent NHibernate with an external configuration file. I kept running into the issue of mappings not being registered. I was finally able to get it working appropriately and thought I would share my solution. The key is to configure the normal mappings...
-
I know I’ve been remiss in my blog posting duties. Please trust me when I say it’s for good reason and that you’d understand. I appreciate you sticking with me. In the meantime, here are a few tidbits that you might find worth noting: Announcing: Zen Nate Kohari (whom I’d like to call a friend, though...
-
I use the following trick for adding ActiveRecord classes after the fact for our in-house plug-in architecture. Thanks to whichever blogger/mailing list I picked this up from so long ago. Scenario 1: Class(es) to load inherit from same base class as current running ActiveRecord classes var holder = ActiveRecordMediator...
-
A few months ago, a coworker created a set of extension methods to turn NHibernate ’s Criteria API into a more fluenty, strongly typed API. We’ve been using it in a production app for a few months, and I wanted to share it with the world. After talking about it with the other Fluent NHibernate contributors...
-
Fluent NHibernate has seen a flurry of development followed by a complete lack of commits, I figure it's time to let everyone know what's going on. The Short Version We're rewriting the internals. We have 100% of tests passing, but still can't guarantee no regressions. Stuff may break...
-
Today we had an issue with our system. The application was showing unexpected behavior when different people where working with different databases. The application is a Silverlight based application. What we found out was that although the application was using different NHibernate session factories...
-
Today the second part of my series on NHibernate and Fluent NHibernate went live. You can read it here . Summary In part 2 of the article series I have continued to implement the remaining part of the domain which I had introduced in the first part . I discuss the mapping of various forms of relations...
-
I have been invited to write a series of articles on NHibernate and Fluent NHibernate on http://dotnetslackers.com . The first part of this series has just been published. I invite you to read it here . In this series I start from grounds up and will explain to the readers how easy it has become to write...
-
I’m in the process of writing an upcoming article for CoDe Magazine about getting started with NHibernate. I’ve spoken with several people about my approach and the majority of them seem to agree that I should use Fluent NHibernate for the mappings instead of the HBM XML. Of course, I will mention...
-
One of the things I’ve been working on recently involves using XML columns in SQL Server. Starting out, it was simple and I was just doing vanilla ADO.NET (wrapped in a simple Query API) combined with XML serialization/deserialization, which worked pretty well for a while. But as the complexity...
-
Several folks, including Microsoft employees and members of the Oxite team, have politely requested I do a post or few on the problems I see with Oxite and why I previously recommended that it is not a good example/sample from which to base future products. At first, I was reluctant to do this since...
-
In the comments of my previous post - Descriptive State Enumeration - Maxim Tihobrazov asked me to show how to map a state pattern with NHibernate; and I am more than happy to oblige! NHibernate Mapping Options I certainly don't claim to be an expert on NHibernate, but I do use it on a daily basis...