Spring.NET + NHibernate - Multiple (Distinct) Databases with OpenSessionInView

て烟熏妆下的殇ゞ 提交于 2020-01-17 03:45:08

问题


In my web application, I have 2 totally different databases - one that's being used mostly by a CMS from which we'd like to get page information on non CMS pages on the same website, & one that contains totally different data.

Is it possible to use Spring.NET's Open Session In View module with multiple session factories for both of those databases, so in this case I have 2 objects defined in spring.config of type Spring.Data.NHibernate.LocalSessionFactoryObject?


回答1:


I think you are talking about the same situation as the user in this forum post

http://forum.springframework.net/showthread.php?p=20720

Let me know if that solutions works out for you.

Cheers, Mark



来源:https://stackoverflow.com/questions/3457911/spring-net-nhibernate-multiple-distinct-databases-with-opensessioninview

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!