Asserting page load times in Magento with Magium

Validating SLAs (Service Level Agreements) is often part of executing browser tests. With Magium you can now include page timings as part of your test. Say, for example, that part of your SLA is that a page must be rendered in less than 5 seconds. This is done by using the TTFBLoadedLessThan, DOMPageLoadedLessThan or DOMContentLoadedLessThan … Continue reading “Asserting page load times in Magento with Magium” Powered by WPeMatico

Excluding fields in the mongodb/mongodb library

I am using the mongodb/mongodb library for a project of mine.  The API seems fairly different from the old PECL library and it also came with some other, albeit unexpected, baggage. My understanding of the library is that it is intended to be a replacement for the existing PECL library and that it intends to strike a balance between the core library functionality while also giving it a more agile, for lack of a better term, release cycle.  What that means is that there is some basic MongoDB functionality written in C with

How to (properly) harness the Magento EE Full Page Cache (part 2 – application states)

In part 1 we took a look at some of the basics of the Magento EE FPC.  We talked about the general structure and flow of the FPC. In this article we are going to take a look at the application states in the FPC.  I don’t know if “states” is the official term, but it’s what I use to describe what they are. There are, essentially, 4 states that the Full Page Cache can be in. Completely cached All containers can be rendered by the processor.  This is the

How to (properly) harness Magento EE’s Full Page Cache (part 1)

TL;DR The Full Page Cache is one of the most important performance features in Magento EE and very few people know how to use it Containers control your content Processors manage containers Knowing containers and processors gets you 90% of the way to solving #1 With my work with ECG one of the more common things I see are performance problems with web sites.  Most often it is due to problems that developers have caused with how they interact with database.  However, that represents the problems I see.  How about the things that people

Be wary of functions in SQL in Magento, such as MAX(). There may be a better way.

I just wrapped up a Healthcheck for a Magento ECG customer and I ran into an interesting issue.  IIRC, the problem wasn’t a client one but rather code that a community extension used.  I won’t mention which one. This extension was generating a query that was looking for the maximum minimum price for all products in a category.  The resulting query was something like this. 1 2 3 4 SELECT MAX(min_price) FROM catalog_product_index_price AS cpip INNER JOIN catalog_category_product_index AS ccpi ON ccpi.product_id = cpip.entity_id WHERE ccpi.category_id = 2;SELECT MAX(min_price) FROM catalog_product_index_price

Load Testing the Magento Checkout with JMeter (and enjoying it)

Load Testing the Magento checkout is, in theory, difficult.  Well, not so much difficult as time consuming.  It is my personal opinion that most Magento load testing is done either poorly or incompletely.  Load testing read-only pages usually means hitting the same page over and over again.  This is counter productive because it allows the system to cache re-used data and skew load testing results to the positive.  I have yet to see a load test that yields performance results that matches production. Testing the checkout is often even worse.  It

Magento, HHVM and the Enterprise Full Page Cache

*** Personal note: It has been suggested that this may reflect an official Magento position.  It does not.  I like doing research and I like publishing what I find as long as I find it interesting and it isn’t tied to a customer.  So if you’re wondering if this reflects a change in Magento or some kind of future roadmap, it does not.  *** I was recently asked by a client about Magento and HHVM support.  While the answer is “don’t touch it in production and there’s no guarantee of support” it

Reasons why Redis is a great option for a worker queue in Magento

Alan Kent asked on Twitter What is your personal favorite HA distributed queue technology? RabbitMQ? Kafka? Redis? ActiveMQ? Why? — Alan Kent (@akent99) February 4, 2015 You may know that I am partial to Redis as a worker queue for Magento.  Here are some reasons why. It is stupid simple to set up (meaning nubes and philes can both use it) It is blazing fast (it’s slow log is measured in microseconds) It does pubsub for one to many It does BLPOP for many to one It’s already supported with the

(New(ish)) Indexing in Magento or “The wonderful world of materialized views”

The Wonderful World of Materialized Views (or, Why Indexing in Magento 1.13 Is So Much Faster) When Magento Enterprise 1.13 came out it boasted massive improvement in index operation performance.  On the Magento blog introducing 1.13 ( a simple statement was made: “The introduction of incremental indexing reduces the need to perform a full re-index and most indexing operations are now automated”.  While this statement is true it provides a very simplified explanation of what has changed and why the improvements in performance are so great. Materialized Views Part of

Testing Magento with random URLs in JMeter

One of the things that I think is important to do in your testing is to introduce some level of randomness into your testing for a web server.   In the wild you have almost no control over what customers are doing on your web site and adding some level of randomness might help you gather additional data, particularly if you are doing it under load. With JMeter this is actually fairly easy.  You have the ability to modify HTTP requests based off of variable values.  In other words, you can