Book review: Magento Performance Optimization How-to
Open source e-commerce platform Magento is widely used and flexible, but at the default settings, it can be dog slow. Packt Publishing recently released "Magento Performance Optimization How-to" by Nayrolles Mathieu in print and ebook format. It aims to be a short, fast and focussed guide to improving the perfomance of Magento stores using practical, hands-on recipes. So is it any good?
The book is only 56 pages long, which I think is a good thing. There is very little unnecessary fluff and the various things you can do to improve the performance of your Magento installations are presented in a clear and concise way, with a simple table demonstrating the performance gains achieved on a test installation. This gives you a nice indication of what to expect. Even in the table of contents, recipes are marked clearly: "Must know", "Should know" and "Become an expert". The recipes span four areas of optimisation: Magento itself, PHP, Apache and MySQL. Not all of these will be applicable for everyone's store, but everyone will find something of interest among the 23 recipes presented, from setting changes for simple single-shop installations to load-balancing and CDNs for large installations.
I started out reading the (ebook version of) this book while sitting on the couch, but quickly found myself at my PC logged in to the development version of my Magento install so I could try out the recipes immediately. The format of the recipes themselves encourages this, with sections "How to do it..." and "How it works..." explanations for each recipe. I certainly came across more than one thing I hadn't known about or hadn't thought of. Some of the recipes involve rather extensive changes to your hosting environment (such as the section on clustering), in which case you should think of them more as a guide on what to do, rather than a step-by-step walkthrough, but it is useful to know these options are available and to get some inkling of what is involved.
I consider the brevity of the book a plus, but there are a few cases where I wish the author had taken a few extra paragraphs to elaborate on a few recipes, especially the ones that might have potentially unintended consequences. For example, it is possible to get the wrong page content if "Blocks HTML output" is cached (which the book recommends) but blocks may not correctly be marked as uncacheable especially with custom templates. The MySQL optimisations in particular could use a little more explanation, as database optimisation is a science in and of itself. And finally the recipe on gzip compression is a little confusion, as there are many ways to do this, some applicable to dedicated hosting, some to shared hosting (largely dependent on the particular shared hosting setup too) and they are not easily distinguished in the book, so this requires a little more technical sense on the part of the reader.
Aside from the aforementioned gripes, I found the book to be quite interesting and useful. The clear way in which each of the recipes is presented, as well as the kind of performance gain to expect, ensures that there is something for everyone. Improvements in your site's performance could have a significant impact on conversion rates, which alone makes this book worth reading and at the very reasonable price of the ebook edition especially, you can't go far wrong. The book deserves a solid 8 out of 10 (4 stars) in my opinion.