Re: Are we using the slowest PHP framework there is?
I never really understood the reason for this hyper-aggressive loading of everything and it's brother, whether you want it or not. It sure would be nice to have the ability to turn off the auto loading, and do a manual loading of only what you need in your action something like a Containable - only for loading. Not every page can be cached, so sometimes you do need to run through the action, yet still have good performance. Admittedly, most apps will not need these optimizations. Given that nothing in this world is perfect, cake does make good choices on the various tradeoffs involved. Perhaps we will see some work in this area when the devs turf php4. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
We can't forget that even not using $uses, when loading a Model it will construct all its links, and its link will construct all of their links, and so forth... So, anyway, you are most probably going to load each and every model by just loading a single one - even though they might have nothing to do with the request. On Feb 18, 11:15 am, mark_story mark.st...@gmail.com wrote: On Feb 17, 8:35 pm, Motin fredrik.mo...@gmail.com wrote: CakePHP does have some issues with aggressive loading, and have terrible performance in a lot of areas, but that benchmark, doesn't really measure anything regarding to Yii. Because of Yii's lazy loading, practically none of the commonly used objects/classes are loaded in the test application. This makes it practically the same as barebones PHP. However, in a real application, when the helpers and models are actually used (and thus loaded), I think the results would look much different. Also, CakePHP is meant to be run with a non-file-based cache engine + a php accelerator. Still, I believe that Yii is much faster for slimmed down applications, and I really hope that CakePHP can learn something from the lazy loading parts (why on earth does Cake load _all_ models in $uses on each request - instead of when they are actually used? for instance). Well PHP4 is one reason. Lazy loading doesn't work so well in PHP4, also using $uses is known to cause performance issues as you end up loading far too many models. You ask about why cake doesn't lazy load, but by using $uses you are doing the opposite of lazy loading. $uses is probably the most aggressive loading strategy you can implement. Using Controller::loadModel() or ClassRegistry::init() is a more _lazy_ approach. -Mark --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
As someone who has written/writing a CMS using CakePHP, even this is not of concern. A bit of mod_rewrite trickery has allowed us to write custom code for very fast viewing content pages, while the administration interface is kept within Cake's MVC. Who cares if the administration interface is a little slow, its unlikely to be getting more than 1500 page views a day. Ned Also the benchmarks measure heavy traffic. That is less important for an Application framework than it is for a CMS. That type of benchmark can never really measure the efficiency of the ORM or any other internal part of Cake. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
On Feb 17, 8:35 pm, Motin fredrik.mo...@gmail.com wrote: CakePHP does have some issues with aggressive loading, and have terrible performance in a lot of areas, but that benchmark, doesn't really measure anything regarding to Yii. Because of Yii's lazy loading, practically none of the commonly used objects/classes are loaded in the test application. This makes it practically the same as barebones PHP. However, in a real application, when the helpers and models are actually used (and thus loaded), I think the results would look much different. Also, CakePHP is meant to be run with a non-file-based cache engine + a php accelerator. Still, I believe that Yii is much faster for slimmed down applications, and I really hope that CakePHP can learn something from the lazy loading parts (why on earth does Cake load _all_ models in $uses on each request - instead of when they are actually used? for instance). Well PHP4 is one reason. Lazy loading doesn't work so well in PHP4, also using $uses is known to cause performance issues as you end up loading far too many models. You ask about why cake doesn't lazy load, but by using $uses you are doing the opposite of lazy loading. $uses is probably the most aggressive loading strategy you can implement. Using Controller::loadModel() or ClassRegistry::init() is a more _lazy_ approach. -Mark --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
CakePHP does have some issues with aggressive loading, and have terrible performance in a lot of areas, but that benchmark, doesn't really measure anything regarding to Yii. Because of Yii's lazy loading, practically none of the commonly used objects/classes are loaded in the test application. This makes it practically the same as barebones PHP. However, in a real application, when the helpers and models are actually used (and thus loaded), I think the results would look much different. Also, CakePHP is meant to be run with a non-file-based cache engine + a php accelerator. Still, I believe that Yii is much faster for slimmed down applications, and I really hope that CakePHP can learn something from the lazy loading parts (why on earth does Cake load _all_ models in $uses on each request - instead of when they are actually used? for instance). On 25 Jan, 21:44, chanon chano...@gmail.com wrote: I know there has been another thread about this, but I want to say that newcomers looking athttp://www.yiiframework.com/performance might be afraid of investing into using CakePHP 1.2. From those numbers, Yii with APC on is about 10x faster than CakePHP (!?) Even compared to CakePHP 1.1, CakePHP 1.2 with APC on is 5 times slower. I feel that maybe before the CakePHP developers rush to add even more features into 1.3, they might want to take a step back and look into improving theperformancein 1.2. As someone said even though faster to develop with is good, but in the current economy people might be interested in saving on server costs too. The benchmark on that site doesn't include any database access, which is something I'd like to see. Maybe CakePHP would make it up when working with a large database? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
There are two things that you all may find helpful: Linkable Behavor: http://rafaelbandeira3.wordpress.com/2008/11/16/linkable-behavior-taking-it-easy-in-your-db/ Lazy Loader Behavor: http://rafaelbandeira3.wordpress.com/2008/11/21/lazy-loader-behavior-what-you-need-when-you-need-the-way-you-want/ On Feb 17, 9:49 pm, Miles J mileswjohn...@gmail.com wrote: One thing I also dislike. Is that cake loads all models, and all models on a model, and it just keeps going down and down. It does this with everything, components on components and what not. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Those benchmarks are flawed and unreliable because I think that the author do not know know to set up benchmarks correctly. He even doesn't care about framework life cycle. Moreover, IMO, Yii is hard to extend. http://www.thedeveloperday.com/framework-battles-yii-vs-zend-framework/ On Sun, Jan 25, 2009 at 12:44 PM, chanon chano...@gmail.com wrote: I know there has been another thread about this, but I want to say that newcomers looking at http://www.yiiframework.com/performance might be afraid of investing into using CakePHP 1.2. From those numbers, Yii with APC on is about 10x faster than CakePHP (!?) Even compared to CakePHP 1.1, CakePHP 1.2 with APC on is 5 times slower. I feel that maybe before the CakePHP developers rush to add even more features into 1.3, they might want to take a step back and look into improving the performance in 1.2. As someone said even though faster to develop with is good, but in the current economy people might be interested in saving on server costs too. The benchmark on that site doesn't include any database access, which is something I'd like to see. Maybe CakePHP would make it up when working with a large database? -- -- http://groups.google.com/group/phpvietnam --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
In my opinion, Performance is no longer the biggest issue in programming. Server cost no longer outweigh development cost. Most companies don't have a huge budget to start a new project. What my company does is, develop a full-fledge programme first. Make the money! If the project fails, FINE! But if it succeeds, move on! Identify the bottlenecks areas. Hire Python developers to switch the bottleneck areas from CakePHP to Python, the fastest programming language in the world. We won't even bother switching to a faster framework. We just go straight to the fastest language and start from there. And there we have, best of both worlds. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Alongside questions about HABTM relationships this is one topic that never dies. :) I have said this before. I have no real-life problems with the speed of CakePHP. I don't know all the other frameworks so there is no way for me to offer a comparative opinion. But I have applications running with several million rows per table by now and Cake keeps going like it is no big thing. I do believe that Cake may have a disadvantage in the mini-app benchmark but that that turns to an advantage when you run into a lot of data and general complexity later on. 0.1 or 0.2 sec for a small application is a lot less helpful than 0.6 or 60 sec when you pile on the data. Also the benchmarks measure heavy traffic. That is less important for an Application framework than it is for a CMS. That type of benchmark can never really measure the efficiency of the ORM or any other internal part of Cake. CakePHP (and Yii?) is primarily designed to build applications, not websites. You don't build something like CakePHP to handle the index- page of cakephp.org. You build it to handle the bakery and the cookbook and other more complex applications. That said, If I was a fan of Yii I would also publish all the benchmarks I could since they showed my framework in a good light. Problem is... who wants to port the bakery to Yii and codeigniter to do a benchmark? :) /Martin On Jan 26, 9:54 am, ProFire profir...@hotmail.com wrote: In my opinion, Performance is no longer the biggest issue in programming. Server cost no longer outweigh development cost. Most companies don't have a huge budget to start a new project. What my company does is, develop a full-fledge programme first. Make the money! If the project fails, FINE! But if it succeeds, move on! Identify the bottlenecks areas. Hire Python developers to switch the bottleneck areas from CakePHP to Python, the fastest programming language in the world. We won't even bother switching to a faster framework. We just go straight to the fastest language and start from there. And there we have, best of both worlds. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Problem is... who wants to port the bakery to Yii and codeigniter to do a benchmark? :) Even those apps were ported to Yii/CodeIgniter/WhateverFasterHelloWorldFramework and it proves to be faster than Cake, I will still use Cake because it makes my code look nice, reduces development time and increases developer (me) happiness. regards, - Dardo. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Even those apps were ported to Yii/CodeIgniter/WhateverFasterHelloWorldFramework and it proves to be faster than Cake, I will still use Cake because it makes my code look nice, reduces development time and increases developer (me) happiness. on a current project of mine, a page with a lot of DB calls with plenty of recursion, takes 0.187s to render, that's plenty quick enough for me. j -- jon bennett w: http://www.jben.net/ iChat (AIM): jbendotnet Skype: jon-bennett --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
I'll probably stick to CakePHP because I love it's design and all the help it gives. I just took a look at Yii and tried to find a helper that can do xxx days ago style date formatting and it doesn't have one. So I can imagine it could be missing lots of small touches like this that make CakePHP a joy to use. But anyhow, performance from 1.1 = 1.2 instead of getting better has gotten 2-5 times worse. Hopefully 1.3 won't continue this trend. As I said, I think instead of rushing to add more features to create a potentially even slower 1.3, maybe it is a good time to optimize what is already there. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Until we all have fibre optic connections, is any of this relevant or important? it is a bit like going to the supermarket in your Ferrari. You might be able to pick up a loaf of bread, but you won't be taking a week's provisions home with you. Learn whichever framework you're using. Design and implement well. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Are we using the slowest PHP framework there is?
I know there has been another thread about this, but I want to say that newcomers looking at http://www.yiiframework.com/performance might be afraid of investing into using CakePHP 1.2. From those numbers, Yii with APC on is about 10x faster than CakePHP (!?) Even compared to CakePHP 1.1, CakePHP 1.2 with APC on is 5 times slower. I feel that maybe before the CakePHP developers rush to add even more features into 1.3, they might want to take a step back and look into improving the performance in 1.2. As someone said even though faster to develop with is good, but in the current economy people might be interested in saving on server costs too. The benchmark on that site doesn't include any database access, which is something I'd like to see. Maybe CakePHP would make it up when working with a large database? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Yes I always hate benchmarks because it only deals with Hello world applications. How about they build robust applications in each framework and then give us a real benchmark that matters. Also Symfony is slower then Cake. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Are we using the slowest PHP framework there is?
Yes, it would be great to have a fully-fledged application example, complete with time to develop and lines of maintainable code benchmarks. And another one which measures mental anguish experienced by the framework. On Jan 26, 7:38 am, Miles J mileswjohn...@gmail.com wrote: Yes I always hate benchmarks because it only deals with Hello world applications. How about they build robust applications in each framework and then give us a real benchmark that matters. Also Symfony is slower then Cake. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups CakePHP group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---