Reputation: 174
My application is interacting with two separate database. I want to inject session factory with spring.net as usually. when I am creating 2 session factory with two separate dbProviders , it is showing error. Is there any way to accomplish this task ?
Upvotes: 0
Views: 334
Reputation: 10557
You have to use a DelegatingLocalSessionFactory
object, available for Spring.NET 1.3.1 and up. According to the docs:
due to variations in the NHibernate project's ISessionFactory API, this approach is only supported under NHibernate 2.1.2 and NHibernate 3.0
I'm not sure about NHibernate > 3.0.
Upvotes: 1