Make your symfony application 70% faster

We wanted to emphasize a particular plugin for the "plugin of the (last) week" series, but a recent post by Pierre Minieur in the symfony mailing-list did it before us. So instead of reinventing the (promotion) wheel, here is an extract of Pierre's thoughts on this plugin:

I'd like to tell you a little success story about using sfOptimizerPlugin. I did many things in my "public" application to optimize performance [and end up having] an average execution time of ~150ms per page, wich leads to ~100ms in the production environment. A little bit slow, I think.

After [installing the plugin and] running $php symfony optimize public staging over the environment, the execution time was reduced by 50ms from ~150ms down to ~90ms, nice. And even the production environment acts faster now, with only ~30ms to serve pages, very nice - 70% faster!

Fabien, thank you for that plugin! It's interesting to see that such kind of "optimizing" can still increase performance, while I thought that symfony caches and compiles so much things that you cannot add additional performance improvements at all :-)

I strongly recommend everyone to add cronjobs on your production servers running this task from time to time to optimize your cached configuration files, your compiled classes and your cached templates, and everything that's not optimized yet ;-).

Note that if you want to share your experience with symfony with the community, we like to publish such use cases here in this blog. Announcements about symfony gatherings can also use this channel. So don't hesitate to send us your (short) articles, they may get published right here.

Comments

Can you tell us a little bit more about the internals of the plugin? What it does? How? and so long.
Thanks
My 15 minutes of fame! ;)
Thomas: I updated the Plugin's page to explain a little how it works. I also updated the plugin itself, which should make it even more efficient.
fabien, any idea what this might do if run against an 0.6.3 project :)
er.. francois.. :P
should'nt this kind of plugin be a part of the core symfony engine ? And this optimization being the default rather than an option.

what do you think ? what would be the reason(s) not to do so ?
@ruzz: I don't think it will work... but it's rather easy to test it ;-)

@marvin: I've created this plugin to test some optimization strategies. It's really a work in progress. And, as it relies heavily on the PHP tokenizer, we have to test it on a large number of configuration to be sure it works for everybody.
Very nice site!

Comments are closed.

To ensure that comments stay relevant, they are closed for old posts.