I'm working in an organisation that makes use of the admin/manual order functionality within the Magento Admin Panel. I've recently added a custom module which has absolutely killed the performance of the page; where products would normally add within a couple of seconds they now take at least 5, rising to 25-30 seconds per item once there are a dozen or so items in the basket. This is too slow when you're trying to process a customer who's on the phone.

The custom module added an attribute to the order (here's the install script):

$installer = new Mage_Eav_Model_Entity_Setup('core_setup');


$salesInstaller = new Mage_Sales_Model_Resource_Setup('core_setup');

$entities = array(

$options = array(
    'type'     => Varien_Db_Ddl_Table::TYPE_BOOLEAN,
    'visible'  => true,
    'required' => false,
    'grid'     => true
foreach ($entities as $entity) {
    $salesInstaller->addAttribute($entity, 'customer_first_order', $options);


Apart from that, the module simply observes sales_order_save_after

<?xml version="1.0" encoding="UTF-8"?>

Moving the observer to frontend seems to make no difference. The module is functioning otherwise as expected. The only other thing I've done was update the admin order grid to show the new attribute. I've tried disabling module output (through admin) and disabling the module altogether (through config XML) and this all has made no difference.

Does anybody have any ideas why this may have slowed that down so much, and what I can do to get the performance back?

Update 1 I've set the threshold for MySQL Slow Query logging at 0.5 seconds and restarted the server. It doesn't seem to be catching any queries related to the order process - which is odd because NewRelic is reporting that /sales_order_create/loadBlock is making a call to MySQL catalog_product_entity_decimal select that is taking 900ms on average. The WebTransaction itself is reported at 1041ms average.


1 Answer 1


In the end, it was absolutely nothing to do with my module, and was the result of another (very) premium module (Ebizmarts Recurring Payments). Once that was disabled, it's going rather nicely.

Only lost 3 days doubting myself! Let that be a lesson not to roll multiple different updates out in a single commit.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.