Posted by caphun on May 7, 2010 at 3:38am
Start:
2010-05-22 14:00 - 17:00 Asia/Hong_Kong Event type:
User group meeting
Thanks all for turning up last month. We had a great time.
This month dalin will be giving a talk on Drupal Performance Tuning and we'll serve more great coffee! There's still space for two more talks so if you have something to share please voice it in the comments below. Or we might have to start doing impromptu talks!
If you want to join us for lunch please come early... around 12:30pm. We will be gathering at the following address:
Rm 1205
12/F, Max Trade Centre,
23 Luk Hop Street,
San Po Kong, KLN
If problems please call: 6776 2825
As physical standing space is limited please signup here.

Comments
I'll be talking more about
I'll be talking more about optimizing web performance in general and this won't be specifically Drupal related though I will show a few Drupal-specific tools. Those of you that also do a lot of Ruby might find it useful as well.
--
Dave Hansen-Lange
Director of Technical Strategy, Advomatic.com
Pronouns: he/him/his
Rah I'll be very interest but
Rah I'll be very interest but I'm not sure to be free this day.
Julien Didelet
Founder
Weblaa.com
HK Meetup is tomorrow!
HK Meetup is tomorrow! Signup here.
--
Dave Hansen-Lange
Director of Technical Strategy, Advomatic.com
Pronouns: he/him/his
Here's the short form of my
Here's the short form of my talk on performance:
Terms
Peformance - How fast a web page takes to display.
Scalability - As your traffic increases does the performance stay consistent? How easy is it to keep things fast as your traffic grows?
The two are often related, but sometimes are in opposition. For example you can load your sidebars via AJAX, but doing so will increase the load on your server and thus decrease scalability.
Don't just randomly apply performance fixes/tweaks/modules/etc.
A doctor would never just start cutting. Diagnose your problem is before you start surgery. Also do a before and after test to make sure your "improvement" is actually helping. For some of these things a slight misconfiguration can make you worse off.
Optimization vs. Caching
These are the two main categories of performance improvements. Generally you can get small gains in optimizing what you already have (<50% improvement). But caching can often bring gains by an order of magnitude. The problem being that you can't always cache things (user-specific or time-specific data).
Automated performance suggestion tools
Things like mysqltuner2, YSlow, Page Speed, etc. Don't alter a setting until you understand how it works. Take the recommendations as only as suggestions - sometimes mysqltuner will tell you to keep increasing a variable when in reality it might actually make matters worse.
Authenticated Users vs. Anonymous Users
These are two separate cases and often need different optimizations. For anonymous users caching can go a long way. Boost is great even for shared hosting. Varnish (a reverse proxy) is even faster, but be prepared to spend some time tweaking it's config file. Varnish can even be useful for authenticated users.
Front End time vs. Query time vs. PHP time vs. Server configuration
Front End
http://spriteme.org/
http://developer.yahoo.com/yslow/
http://code.google.com/speed/page-speed/
$(window).load(function(){var head = $("head").first() || document.documentElement;
var script = document.createElement('script');
script.type = 'text/javascript';
script.async = true;
script.src = 'some_script.js';
head.insertBefore(script, head.lastChild);
});
$('.some-class')...
IDs are best.
$('#some-id')...
Query Time
The database can be your Achilles Heel if you've got poorly built queries. Generally a query that takes longer than 1ms is a problem.
PHP time
Page generation time - query time = PHP time.
Server Configuration
This is a talk for another day.
Other measurement Tools
Apache Bench - great for doing a quick and easy before-and-after test. Only measures the time to generate the HTML document, does not include CSS/JS/images etc.
JMeter - good for more advanced testing - simulating several different users traversing different paths through your site.
Drupal specific stuff
I think that's most everything that I covered.
--
Dave Hansen-Lange
Director of Technical Strategy, Advomatic.com
Pronouns: he/him/his
Thanks!
Thanks for the great write-up Dave and the excellent talk! Look forward to more like these in future. :)
Thanks to all who attended too!
Thanks Dave ! It will be
Thanks Dave ! It will be really useful for me too :).
Julien Didelet
Founder
Weblaa.com