Are you guys caching anything. That will do tons for you. Also, I'd look into using InnoDB for your database if you're using MySQL. If I'm getting what you're telling me right, it looks like there are some configurations you need to tweak in your server config. If MySQL is what's crashing your server, I wouldn't worry too much about the PHP code, and look more into which queries are taking the longest.
Take a look at your slow query log, and turn it on if it's not already on: http://www.databasejournal.com/features/mysql/article.php/2013631 This is a great article on optimizing php: http://phplens.com/lens/php-book/optimizing-debugging-php.php There's something called 'Apache Bench', which I've actually never used, but the guy who wrote the article above did. Maybe that can help you test your server. Nice site by the way ; ) On Jul 31, 10:55 am, PiLLo <[EMAIL PROTECTED]> wrote: > Hi housebolt, I would like to know a tool capable of simulate a heavy > load on the server in order to identify which part of the code is > producing a bottle neck. > > On development environment everything seems ok, but on production > environment I set 0 the debugger flag , but I am missing something > because on a demand of 600 concurrent users, MySQL puts the processor > at the top and it all falls down. > > So the team decides to comment some queries in order to reduce the > load, the hardware arquitecture is formed by: > - one server on the front > - a second server to attendant the database > > There isn't a loadbalancer and the site is here:http://www.hola-tu.com > > On Jul 30, 5:09 pm, gwoo <[EMAIL PROTECTED]> wrote: > > > There are two reasons to avoid $uses and loadModel in your code. > > > 1. performance: > > Extra memory will be consummed if you have var $uses and the > > association in your model. > > loadModel simply checks if the class exists and includes it if it does > > not, so the overhead here is minimal. But then you need to create the > > instance so memory is increased. If you go this route, use the > > ClassRegistry. By using the registry when you need to gain access to > > an object you can be assured that you are not adding any extra > > overhead. > > > 2. maintainability > > everyone knows we are concerned with maintainable code. We provide var > > $uses for the exceptions to the rule (ie: contact form, search, etc) > > These are cases where there is generally no model for that controller > > and so there is a need to override the default behavior. On the other > > hand, loadModel can create spaghetti plain and simple. Using loadModel > > can be likened to using sql in your templates, albeit a little more > > elegantly. > > > But this is really off topic, because I doubt the site is running slow > > because of the model loading. It is most likely an issue with server > > load and/or max clients on apache. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---