How do you handle Membership/Roles when using NHibernate?

馋奶兔 提交于 2019-11-28 19:21:53

问题


I'm about to kick off a new project using NHibernate and ASP.Net MVC and have come upon the question of membership. I'm wondering if I should use a 3rd party NHibernate Membership/Role provider, create my own, or just skip the providers all together.

So far I've looked at:
Manuel Abadia's NHCustomProviders - It seems like a lot of configuraton, not sure if I want to put all that in my web.config.
Leo Vildosola's NHibernateProvider - Which doesn't appear to be supported by the project owner anymore since he doesn't use NHibernate anymore.
Eucalypto - I like the table structure, but am a bit warry of all the extra CMS stuff it comes with.
* Each of these projects looks like it hasn't been touched in a while, which could mean extra work just getting them updated to use the newest version of NHibernate.

This is one of those problems that's been solved many times and I would like to spend my time solving new problems, and hopefully adding some business value.


回答1:


I rolled my own. It's actually a lot easier than most people think (I was surprised too) - once you actually get rolling, everything comes together pretty quickly. It's one thing to spend days or more solving a solved problem, but this took me all of a few hours including planning.



来源:https://stackoverflow.com/questions/512922/how-do-you-handle-membership-roles-when-using-nhibernate

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