I've been following this group for a few weeks now, and it is an excellent source for information on boosting Drupal performance. The contributors, especially regular contributors, do a great service with their efforts.
One thing I find daunting, however, is that someone new to this topic can be overwhelmed by the breadth and depth of the information. Of course, that is more a good thing than a bad thing because we should all rather have too much info rather than too little info.
Yet, I've tried to bootstrap my understanding by reading almost everything here and creating summaries of most topics. Even with this, I find it hard to get perspective on what I should be focusing on as I built my Drupal site. I've spent a LOT of time doing this.
As someone who worked for years in computer hardware design and performance optimization, I should be able to do a better job of bootstrapping myself. I'm not new to the general issues relating to performance. Yet, so far, I haven't been able to do so.
That said, what I would love would be to find a reference that covers (for PHP applications generally, or Drupal specifically):
1. measuring performance (generating performances tests and logging the results)
2. analyzing performance (identifying bottlenecks based on test results - I can probably figure this out myself from past experience)
3. improving performance through caching, with a discussion of various tools/techniques including tradeoffs and limitations (whether to cache is not the question; how to cache is the question)
Admittedly, much of this information exists somewhere in this group, on the Drupal website, or on other websites. Some of that info is very illuminating, while other info is merely conclusory (e.g., "Be sure to use APC!")
Would anyone know of a single book or URL that provides at least a foundation for the three topics above (specific to PHP at least, if not to Drupal)? I am currently reading the Drupal Performance book from Packt but recognize its target audience may be different than this group.
Thanks in advance for any help
Dave
P.S. I welcome RTFM advice if you'll point me to it ;)
Comments
Packt's book has been razzed
Packt's book has been razzed by a lot of people in the community for not being very useful. See this comment thread, this review ("this $40 waste of paper"), this review, and so on.
I think one of the big obstacles to writing a definitive guide to Drupal optimization is that there are so many possible variables to one's situation. Advice like "Use APC" doesn't work for those on shared hosting or RAM-limited VPS accounts, but these people can usually use Boost just fine. Varnish is great… if you have more than one server to work with. CDNs are great… if you can afford them. MySQL configuration tuning is great… but probably not an option for those on shared hosting. Etc, etc.
That being said, perhaps there is a place for some sort of guide which collected a bunch of how-tos for improving Drupal performance, with each guide rated on potential audience (shared hosting users, VPS users, dedicated server owners, multiple server owners) and difficulty of implementation (n00b, savvy, technical, neckbeard). Might make a good weekend project… hmm.
The Boise Drupal Guy!
Books
Speaking of books, I've thought about writing a book on Drupal performance. Some of the tips I was thinking about, I turned into the dbtuner module. The problem with performance is if you want to gain a lot, you will most likely need some custom code.
Best example of custom tuning is turning a view into a cached object and using hook_nodeapi to update the object so it only changes when the node changes. Using this trick I was able to reduce the database load almost in half for logged in and logged out users (we have some expensive view queries). The generalized form of this is http://drupal.org/project/views_content_cache. Haven't looked at the module yet but sounds like it does exactly what I did (module is a week old).
Long story short, we are still trying to figure out what works the best and most of us will try to release it as a Drupal module if it's generalized. Performance tips/tricks is all about building off of the next idea. Good example of this in core is lock.inc. Now that this is in we have been rewriting a bunch of core to take advantage of it.
http://drupal.org/node/147000#comment-3090938
http://drupal.org/node/561990#comment-3129014
http://drupal.org/node/512962#comment-2819410 - This one needs some work
Just so I'm following along
Just so I'm following along correctly here… The primary benefit to using this locking system, performance-wise, is to avoid situations where heavy but cacheable operations are happening concurrently, correct?
The Boise Drupal Guy!
Correct
For certain setups & situations we are talking about minutes to seconds
http://drupal.org/node/307756#comment-2887184 - This is the issue that was rolled into 147000
Why write the same info to the database 10 times. This is the idea of the locking system that was introduced in 6.16
Great modules @mikeytown2
Great modules @mikeytown2 ,thanks
Potential audience
I prepared a guide on performance a few months ago which did focus on the different audiences. It was the result of trawling this group for tips and tricks. I broke performance problems down into a number of dimensions:
See the first article in the series or the quick reference of possible solutions. If anyone has any further suggestions I'd be happy to incorporate them in.
Managing Director
Morpht
Nice
Murray,
Thanks for pointing me/us to your series of articles! They collect a lot of good information in one place, which is what people new to the topic need so they can plausibly come up to speed.
Dave
Agreed. I wasn't able to look
Agreed. I wasn't able to look at all of it - or even most of it - but there's definitely some comprehensive stuff there, and may be of more use to more people than the Packt book. Good work.
The Boise Drupal Guy!