Book Image

Magento 2 Development Cookbook

Book Image

Magento 2 Development Cookbook

Overview of this book

With the challenges of growing an online business, Magento 2 is an open source e-commerce platform with innumerable functionalities that gives you the freedom to make on-the-fly decisions. It allows you to customize multiple levels of security permissions and enhance the look and feel of your website, and thus gives you a personalized experience in promoting your business.
Table of Contents (13 chapters)
12
Index

Benchmarking a website


When you have a high-traffic site, you would probably want to know the limits of the website. What will be the capacity of my website when I launch a marketing campaign? What is slowing down my site? Which optimizations have the most effect?

To know the limits of a website, we have to use benchmarking tools. With a benchmarking tool, we will create a load on the website and log the response time to a file. By increasing or decreasing some values, we can determine the load that is the limit of a website.

In this recipe, we will benchmark the Magento site by doing some tests with ApacheBench and Siege. With these tools, we can measure the performance of different pages.

Getting ready

For this recipe, we need some tools that need to be installed on the webserver. Ensure that you have the following tools installed:

  • ApacheBench (ab): This tool can be installed using the sudo apt-get install apache2-utils command. When this is installed on the server, you can use the ab -h command...