nhibernate是否可以用于诸如Facebook之类的大型项目? (为了论证) [英] Would nhibernate be used in large scale projects like say facebook? (for arguments sake)

查看:131
本文介绍了nhibernate是否可以用于诸如Facebook之类的大型项目? (为了论证)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对于那些了解nhibernate内部工作原理的人,您认为像facebook/myspace这样的大型Web应用程序会使用nhibernate吗?

还是nhibernate非常适合于公司站点等流量较小的站点?就是说,由于其健谈的性质而不能为企业做好准备吗?

解决方案

NHibernate一点也不健谈.关于可伸缩性,已经有一个对NH的组的疑问 ,这更多的是关于数据库的复杂性,然后是流量,但对您来说可能仍然很有趣.

即使总是有关于每个ORM上不必要的查询的投诉,由于ORM的一般性质,这并不意味着它是健谈的.另一方面,它可以优化复杂的情况,以至于无法在手写DAL中进行优化.例如.查询批次或延迟加载.

与其他ORM及其强大功能相比,NHibernate的重量很轻.

如果没有面向对象的业务模型,但是您需要进行优化以获得最高性能,则可以将NHibernate(与其他任何ORM一起)视为过大杀伤力.例如,我认为Google不能在其搜索引擎中使用NHibernate.


NHibernate的性能和功能不是完全免费的.它要求开发人员至少了解有关关系数据库的基础知识.其他ORM试图隐藏整个关系问题,这导致了更多未优化的行为.

For those who know the inner workings of nhibernate, do you think a large scale web application like say facebook/myspace would use nhibernate?

Or is nhibernate well suited for more low traffic sites like company sites etc? i.e. not enterprise ready because of its chatty nature?

解决方案

NHibernate is not chatty at all. About scalability, there was already a question on NH's groups, which was more about the complexity of the database then traffic, but might still be interesting for you.

Even if there are always complaint's about unnecessary queries on every ORM, because of the generic nature of an ORM, it doesn't mean that it is chatty. On the other hand it optimizes situations where it would be too complex to optimize in hand-written DAL's. Eg. query batches or lazy loading.

NHibernate is quite light-weight compared to other ORM's and compared to it's powerful features.

NHibernate (as any other ORM) could be considered to be overkill if there is no object oriented business model but you need to optimize for highest performance. I don't think that Google could make use of NHibernate for its search engine, for instance.


Edit:

The performance and power of NHibernate is not fully for free. It requires that the developers understand at least the basics about relational databases. Other ORM's try to hide the whole relational problematics, which leads to much more unoptimized behaviour.

这篇关于nhibernate是否可以用于诸如Facebook之类的大型项目? (为了论证)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆