The maintenance window was the bigger outage

We wanted to know what a maintenance window really costs a Magento store, against the alternative. Our deploy playbook takes one whenever a release has database work to do: every web server switches to the new code at once, the store shows its maintenance page while setup:upgrade runs, and then it comes back. The alternative is harder than it sounds. A rolling release, a canary or a zero-downtime deploy all need two versions of the code serving from one database at the same time, and Magento pushes back on that in three layers. It refuses pages when a module’s version doesn’t match the database. It refuses requests when the deployed configuration doesn’t match the imported one. And nothing at all protects a query that meets a schema it doesn’t match. A flag, deployment/blue_green/enabled, switches off the first two. Nothing switches off the third. ...

September 30, 2026 · 5 min · Luis Tineo

Every Magento login downloads every country on earth

On 7 September we went looking at customer/section/load on a stock Magento 2.4.8 store with the sample data. It’s the request that fills in everything a cached page can’t know about you: your name, your cart count, your messages. It can never be cached, so every call boots the whole application. One response was 61,194 bytes. About 59 KB of that was directory-data: every country and every region the store knows. The same list for every visitor on the planet, travelling through the one channel in Magento that exists because responses can’t be shared. ...

September 24, 2026 · 5 min · Luis Tineo

Rereading my 2012 nginx config: the block that runs your uploads

The PHP-FPM reread ended on a promise. The same July 2012 post, PHP Offloading… Nginx helps so much!, hands over an nginx server block, and one location in it has a problem that has nothing to do with performance: location ~ .php$ { ## Execute PHP scripts if (!-e $request_filename) { rewrite / /index.php last; } ## Catch 404s that try_files miss ... fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; ... } “Execute PHP scripts” is exactly what it does. Any request ending in .php goes to PHP-FPM, and PHP-FPM runs whatever file nginx names. Nobody asks whether that file was ever meant to be a script. So if somebody can get a .php file into a folder the web server serves, through an avatar upload, an import, a product image field that checks the extension a bit too loosely, that file runs. ...

September 24, 2026 · 3 min · Luis Tineo

Rereading my 2012 Varnish post

In July 2012 I wrote a post called Varnish implementation hints and good to know. It opens with “Sharing knowledge is always a good idea,” and then shares, in order: a set of bash aliases that switch Varnish on and off with iptables, a header that tells PHP whether Varnish is in front, a cookie-stripping regex, a one-line purge, and what it calls “a favorite of mine”, a function that walks every URL in the sitemap so you can clear them all. ...

September 24, 2026 · 4 min · Luis Tineo

From a 2015 docker-compose file to Kapelos

In 2015, at BuyerQuest, I wrote a docker-compose file that ran Magento on my computer. I took it with me to Anatta, and then to Scrubs & Beyond. This week it became Kapelos, a public project anyone can clone. Most of the file changed over those years. What I built it for never did: one Magento store, on one computer, from a file I can read top to bottom. The oldest copy I still have The oldest version I still have is from March 2019. It’s Compose format 2.2, with thirteen services: ...

September 11, 2026 · 5 min · Luis Tineo

Zend Queue with Magento

By using Zend Queue with magento we can create an event driven asynchronus integration system. Just think about how much work you will offload from Magento when integrating with other systems and Magento itself. To keep things simple, let’s pretend that you send emails to your customers everytime a new product gets added. Usually these products get added during the day which also happens to be when your customers are most active buying in the site. An alert about a new product is very important but you don’t want to bug down your email server. That’s where Zend Queue comes to the rescue. In this example I am using mysql to store the queue. If you follow the same example remember to create the tables first, these can be found under: lib/Zend/Queue/Adapter/Db/mysql.sql ...

August 1, 2012 · 2 min · Luis Tineo

Cloning magento modules

Cloning magento modules will never this easy again. Today I wanted (read was forced) to create a module based on one of Magento’s core. Literally I needed to clone some of the Magento modules and while the copy and paste is simple stuff, going class by class and file by file renaming and configuring files is not joke. So why do I need to clone it instead of just doing the usual OOP stuff Magento is so good at? Simply because the functionality is really different in most files and settings. So creating a payment method or paygate or giftcard module is easier when you have an skeleton to work with. Think about it, how different is paying with PayPal from Google Checkout? Functionality wise not that much, essentially they do the same thing but implement it differently. ...

August 1, 2012 · 3 min · Luis Tineo

Full Page cache with nginx and memcache

Since the cool kids at Google, Microsoft and Amazon researched how performance and scalability affect conversion rates, page load time has become the topic of every eCommerce store. Magento was once a resource hog that consumated everything available to it and you had to be a magician to pull off some awesome benchmarks without using any reverse proxy or full page cache mechanism. Creating a full page cache with nginx and memcache is really simple (right after hours of research). ...

August 1, 2012 · 4 min · Luis Tineo

Dirt cheap way to make magento fly

There are several ways to accomplish the same task and some are more elegant than others. This one makes any Magento community edition fly and is cheap and quick (read no Magento compliant - because it modifies the templates) In other words while this trick can help you boost your Magento store server response I am not too proud of it. Why is that a big deal? I am not a huge fan or changing templates, even if they are “allowed”. ...

July 27, 2012 · 6 min · Luis Tineo

PHP Offloading... Nginx helps so much!

So let’s continue our attempt to improve Magento’s performance and this time around let’s focus on the web server itself. There are a bunch of web servers out there but the most known are, a least to me: Apache, Nginx and Lighttpd My favorite, and of course I am biased here, is Nginx and it approach to serving content. As you may all know Nginx is an event-based web server and the main advantage of this asynchronous approach is scalability. ...

July 26, 2012 · 3 min · Luis Tineo