# Ruby on large scale projects, and cakephp

**URL:** <https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350>\
**Category:** Rails\
**Created:** [March 1, 2007, 11:06pm UTC](https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350 "2007-03-01T23:06:55Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![emre](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/71e660/32.png) [@emre](https://www.ruby-forum.com/u/emre)\
**Post date:** [March 1, 2007, 11:06pm UTC](https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350/1 "2007-03-01T23:06:55Z")

</div>

I’m new to Ruby and I have a few questions about it.

How does Ruby scale to large-scale web applications? For example, if  
YouTube were written in Ruby, would it be as fast as it is now?

Another question is how do you compare CakePHP with Ruby?

Thanks.

---

<div class="post-metadata">

**Author:** ![emre](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/71e660/32.png) [@emre](https://www.ruby-forum.com/u/emre)\
**Post date:** [March 2, 2007, 12:12am UTC](https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350/2 "2007-03-02T00:12:04Z")

</div>

> I’m new to Ruby and I have a few questions about it.
> 
> How does Ruby scale to large-scale web applications? For example, if  
> YouTube were written in Ruby, would it be as fast as it is now?

> **[Getting Real](https://basecamp.com/gettingreal)**
>
> The smarter, faster, easier way to build a successful web application

> Another question is how do you compare CakePHP with Ruby?

We don’t. CakePHP is a framework (written in PHP), an Ruby is a  
programming language  
(in which Ruby on Rails framework is written).

## Regards, Rimantas

[http://rimantas.com/](http://rimantas.com/)

---

<div class="post-metadata">

**Author:** ![emre](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/71e660/32.png) [@emre](https://www.ruby-forum.com/u/emre)\
**Post date:** [March 3, 2007, 2:54pm UTC](https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350/3 "2007-03-03T14:54:48Z")

</div>

Hi emre!

I’ll prefix all my comments below by saying that I am a professional  
PHP programmer for both small and large-scale apps. I’m also doing  
growing amounts of Rails programming. I use CakePHP from time-to-time  
for several projects that are restricted to running on PHP4 servers.

> How does Ruby scale to large-scale web applications? For example, if  
> YouTube were written in Ruby, would it be as fast as it is now?

Rails scales quite well. You will notice that “out the box” rails will  
be a bit slower than any simple non-framework PHP scripts you have  
written in the past. This slowdown is more than worth it in my opinion  
because you are able to quickly bootstrap applications in Rails and  
get them up and running. At that point Rails is ready to scale out and  
be fine-tuned for performance. Also - say your PHP app is running  
slowly - how will you profile it and figure out what is slowing down?  
Rails has this built in.

> Another question is how do you compare CakePHP with Ruby?  
> They are actually quite similar - CakePHP has pulled a good many ideas  
> and even names of methods from Rails.

That being said, you will quickly notice that Rails has much more  
elegant syntax (thanks to Ruby) and that you can do quite a bit more  
things with less work.

Lastly - one thing that you may think is cool coming from a PHP world  
(I did) was that a Rails project includes its own web server built  
into the code (look into the “ruby script/server” command). You won’t  
have to fool with running a full web stack on your development  
workstation or uploading files to a server to see how they run.

If nothing else, learning Ruby/Rails will no doubt help your PHP  
programming - it will force you to think in new ways.

Got any more questions? Feel free to give me a shout back.

Wes

---

<div class="post-metadata">

**Author:** ![emre](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/71e660/32.png) [@emre](https://www.ruby-forum.com/u/emre)\
**Post date:** [March 3, 2007, 10:05pm UTC](https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350/4 "2007-03-03T22:05:50Z")

</div>

Each time I see the "how do you compare the speed/scalability of Ruby/  
Rails with \<insert language/platform here\>, I’m reminded of the  
following piece of wisdom: A good algorithm beats machine  
optimizations every time.

With Ruby, and particularly with Rails, the path to working code is  
quite fast. When you spot a bottleneck, you have time to think through  
your algorithms, and come up with something clever. I’ve yet to see  
any deal-breakers in Rails, but I haven’t been slash-dotted yet 🙂

---

<div class="post-metadata">

**Author:** ![emre](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/e/71e660/32.png) [@emre](https://www.ruby-forum.com/u/emre)\
**Post date:** [March 4, 2007, 3:24am UTC](https://www.ruby-forum.com/t/ruby-on-large-scale-projects-and-cakephp/87350/5 "2007-03-04T03:24:19Z")

</div>

Thanks for all the replies. Actually, I’ve started coding my project  
in Rails and that’s very exciting!
