是否有基准比较django,rails和PHP框架的相应内存使用? [英] Are there benchmarks comparing the respective memory usage of django, rails and PHP frameworks?

查看:200
本文介绍了是否有基准比较django,rails和PHP框架的相应内存使用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须在具有有限RAM(1 GB,无交换)的嵌入式服务器上运行具有多种服务的Web服务器。将有最多100个用户。我会有一个论坛,小游戏(javascript或flash)等服务。

I have to run a Web server with many services on an embedded server with limited RAM (1 GB, no swap). There will be a maximum of 100 users. I will have services such as a forum, little games (javascript or flash), etc.

我的团队非常熟悉Ruby on Rails,但我有点担心Rails的内存使用。我真的不想在这里开始一个巨魔,但我想知道是否有任何严重的(即文档)基准比较Rails,Django,CakePHP或任何其他PHP框架?

My team knows Ruby on Rails very well, but I am a bit worried about Rails' memory usage. I really do not want to start a troll here, but I am wondering if there are any serious (i.e. documented) benchmarks comparing Rails, Django, CakePHP or any other PHP framework?

你能指向基准或给我你对Rails的内存使用的意见吗?

Could you please point to benchmarks or give me your opinion about Rails' memory usage? Please please please no troll.

推荐答案

在内存使用方面,它通常是Python> Ruby> PHP,当然导致Django> Rails> CakePHP。不仅仅是内存,但也倾向于保持原始性能。编辑:还值得注意的是,当然,这里没有绝对。有很多使用场景,其中Ruby会打败Python,双手。我想我们都同意Ruby和Python总是会击败PHP,虽然:)

In terms of memory usage it's generally going to be Python > Ruby > PHP, which of course leads to Django > Rails > CakePHP. Not just memory but that also tends to hold for raw performance. Also worth noting that there are, of course, no absolutes here. There are plenty of usage scenarios in which Ruby will beat Python, hands down. I think we can all agree that Ruby and Python will always beat PHP, though :)

这里是一个直接的3路基准测试事情): http://wiki.rubyonrails.com/rails/pages/Framework+Performance 。虽然当然很容易找到统计数据来支持自己的观点:)

Here's a straight-forward 3-way benchmarking (with Symfony on the PHP side of things) that bears out the above: http://wiki.rubyonrails.com/rails/pages/Framework+Performance. Though of course it's easy to find stats to support your own viewpoint :)

也就是说,仍然很容易做出一个cr脚,慢,低效的Django应用程序和精益,快速,高效的Rails应用程序,反之亦然。与您使用的系统相比,您的技能,知识和专业知识将为其内存和性能足迹做更多的工作,而不仅仅是框架本身。数据库优化,服务器选择和架构(使用nginx / lighttpd等的Apache vs.代理设置)和基本设计决策很可能会快速压倒框架的固有特性。

That said, it's still very easy to make a crappy, slow, and inefficient Django application and a lean, fast, and efficient Rails application, or vice-versa. Skill, knowledge, and expertise with the system you are using will do far more for its memory and performance footprint than just the framework itself. Database optimizations, server choices and architectures (Apache vs. proxy setups using nginx/lighttpd, etc.), and fundamental design decisions are likely going to overwhelm the framework's inherent characteristics pretty quickly.

所以我想我的意思是,如果你的团队知道Rails,你的专长在于Rails,我会坚持Rails。

So I guess what I'm saying is if your team knows Rails, and your expertise lies in Rails, I would stick with Rails.

这篇关于是否有基准比较django,rails和PHP框架的相应内存使用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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