Blog Posts: Latest Trends and Insights in Technologies | Clarion Technologies

Load Testing For Your Ecommerce Site

Written by Ajit Pendse | May 11, 2016 6:30:00 PM

Today, the Internet is home to some of the biggest businesses. According to market research firm Statistica, in 2016 global eCommerce sales are expected to reach 1.9 trillion U.S dollars. While the traditional brick and mortar store is yet to become redundant, eCommerce websites have a pretty penny riding on their backs. Today, the consumers do not separate online shopping experience from the regular store experience. Thus, we won't be off the mark to say that in an eCommerce business, your eCommerce site is your salesperson, your workhorse who increases value for your customers. With so many eCommerce websites mushrooming all over, you need to make sure your salesperson is the best.

In one of our previous blogs, we had identified some critical elements for building great eCommerce websites. In this blog, we take a look at another critical aspect of an eCommerce website – Load Testing.

Why is Load Testing Important?

Essentially, load testing is a lot like business risk mitigation. It is the measure to see how your eCommerce site will manage website load, identify how quickly product pages will load, see how it will handle traffic spikes and find potential performance bottlenecks. Take the example of Flipkart’s Big Billion Day Sale’s epic failure in 2015. The eCommerce provider announced the mega sale but most of the customers were left disgruntled as stocks were limited, orders got mysteriously cancelled and the website, which was unable to handle the huge surge in visitors, crashed several times. While Flipkart and the Big Billion Sale did trend on Twitter, it was for all the wrong reasons.

Now that we have established the importance of load testing let’s take a deeper dive into understanding it better. During load testing, all performance tests are run simultaneously over a decided period of time to assess how the systems performance. Though load testing is not a very difficult task, it does require some time investment to ensure that businesses don’t lose revenue. After all, a one-second delay in load time can lead to 7% fewer conversions. That would mean a loss of USD $2.5 million per year for a company earning $100,000 per day. Here’s a look at how you can plan load tests.

What to Test?

The first step to load testing begins with understanding what to test. When load testing is being done for an existing website or an existing website is being updated, a good point to start is by looking at web analytics to identify traffic patterns. When load testing a brand new site, traffic analytics can be done by reaching out to a third party traffic source. Some other questions to ask while load testing are:

  • How do different kinds of traffic, such as anonymous and authenticated users etc., affect site performance?
  • What are users doing on the site (mostly browsing, mostly buying, etc.)?
  • Are there any logical groupings present?
  • Are transactional flows being processed without glitches?
  • Identifying caching layers to see how traffic is getting to the website.

Monitoring and Setup:

During load testing, you need to plan for ‘gotchas’ that derail site performance. For this, you need to monitor overall server metrics such as memory utilization, CPU utilization, disk I/O, etc. You also need to tail your load balancer’s access logs. In addition to this, you need to check the application components such as the database, hardware, and network to manage future anticipated load. Monitoring network devices such as routers, firewalls, and load balancers help in identifying network-related problems. During load testing, here is what should be tested:

  • The number of concurrent requests that can be handled by a system.
  • The acceptable response time for test paths.
  • The points in the chain that consume the most number of hardware resources.
  • The failures caused by large data sets, increased number of users or products, orders, etc.
  • Optimization of code paths and database queries by caching.
  • Application performance profile.

How to Test?

Once the traffic profiles and behavioural data has been collated, the load tests should be conducted on the basis of how the users interact with the website. The first step is to establish the benchmarks that the eCommerce website should meet to set the test goals and configure test scenarios that represent realistic user activities. Some useful metrics while load testing are:

  • Number of successful transactions.
  • Ratio of errors v/s success in the number of page views per minute.
  • The page load time – Anything over five seconds increases site abandonment rates.
  • The real errors that users encounter by running tests with real browsers which include time out errors and content errors.
  • If throughput increases as the amount of load on the system increases. The difference in throughput levels when additional users are applied signals a problem and might need checking if there is a bandwidth issue by checking with the Internet Service Provider (ISP) or if some page assets need to be shifted to a content delivery network.
  • Assessing if the application collapses after a certain number of users by checking memory usage in the application server.

 

For an eCommerce website test script should:

  • Randomly create products.
  • Randomly create orders (fill up a cart, then go to checkout).
  • Randomly create customer accounts (can combine this with creating an order script).
  • Make changes in the admin interface (creating categories, configuration changes).

Once the baseline test has been created, run the test and check for response time, latency time, the number of hits per second and the throughput and the number of errors. Once round one is complete, re-run the test increasing the number of page visitors per duration and also increase the duration of the test load. This will help in identifying memory leaks and unforeseen service or application restarts.

At the offset, load testing seems quite simple to execute but in reality can be slightly complex as testers need to check for all possible variables and optimizations. However, it is a very important component for eCommerce success as any downtime once the site is live can have a negative impact not only on the immediate revenue but also on customer loyalty.