Yesterday, I had to upgrade from Spring.NET 1.1 to Spring.NET 1.2 in order to use Quartz.NET. After doing that, I started to get InvalidCastException errors in my unit tests that told me I couldn't convert an int to a Nullable<int>. Things like this were broken:
void TestMe(int? id)
{
// do testing here
}
// and elsewhere, we call it like this
TestMe(42);
Very strange. It turns out that this is a known (and fixed) issue due to using Nullable types through AOP. I grabbed the latest nightly build and all of the tests passed again.
However, when running, I found a breaking change in the post-1.2.0 code that I needed to correct, namely:
Overriding the SessionFactoryObjectName in web.config no longer uses Spring.Data.NHibernate.Support.OpenSessionInViewModule.SessionFactoryObjectName as the key. Now, you need to use Spring.Data.NHibernate.Support.SessionScope.SessionFactoryObjectName. e.g.
<add key="Spring.Data.NHibernate.Support.SessionScope.SessionFactoryObjectName"
value="NHibernateSessionFactory" />
Now everything is upgraded and working again.