Troubleshooting History
Real problems. Actual root causes. Fixed.
Here is how I tracked down and resolved stubborn issues on production WooCommerce sites that other attempts failed to fix.
Database Performance • UK Retail Store
Fixing a 7-Month WooCommerce Database Deadlock
The Problem
A busy UK online store was freezing at checkout during peak shopping hours. Orders dropped out midway, and their warehouse inventory sync kept failing with timeout errors. This had been going on for seven months.
What Was Actually Happening
I reviewed the MySQL query logs and inspected the wp_options table. An older plugin had left behind 5,686 expired transients that were set to autoload on every page request. Worse, one single cached row had ballooned to 11 megabytes. Every time a customer checked out, MySQL had to lock the entire table while writing to that bloated row, causing every other buyer to time out.
The Fix
I safely purged the dead transients using WP-CLI, stripped the oversized row out of autoload, and set up a routine cron job to keep transient data clean. The database table locks dropped to zero immediately, and checkout errors stopped completely.
5,686
Dead Transients Removed
11 MB → 24 KB
Cache Row Size Reduced
0
Subsequent Checkout Timeouts
Caching Issues • Staging & Production Sync
Untangling Caching Conflicts After a Redesign
The Problem
Right after a redesign launch, customers started noticing items disappearing from their carts. Category pages were showing outdated stock counts, and the admin dashboard was throwing frequent 504 Gateway Timeouts.
What Was Actually Happening
The site had two separate caching layers fighting each other. The server had an Nginx page cache running without proper cookie exclusions, meaning it was saving and serving cart pages to the wrong users. At the same time, an optimization plugin was trying to combine JavaScript files that had already been minified by the theme, causing script errors on checkout.
The Fix
I stripped out the duplicate minification settings and reconfigured the server cache to respect WooCommerce session cookies. Page load times dropped from nearly three seconds down to 320 milliseconds, and carts stayed isolated to each customer.
320ms
Response Time (Down from 2.8s)
100%
Cart Sessions Isolated
Payments & Forms • Client Handover
Fixing Webhook Failures and Form Spam
The Problem
A merchant was dealing with orders stuck in “Pending Payment” status because payment notifications were not reaching the store. On top of that, their staff inbox was getting flooded by hundreds of automated spam submissions every day through their contact forms.
The Fix
I rebuilt the payment gateway connection using Square, verified the webhook endpoints directly with the gateway, and added a silent honeypot check to all site forms. The spam dropped off right away without forcing real visitors to solve annoying image captchas, and order statuses began updating automatically again.
99%
Spam Submissions Stopped
100%
Payment Webhooks Delivered
