We’ve build a REST service with ASP.NET MVC Web API in Visual Studio 2013. With a Load test we plan to test the performance of the service when deployed to a web server with the data on a sql server. After completing a test run with over 100000 successful tests we looked at the summary report.
The pages/sec are not on par with the requests/sec, average page time and other metrics. We expected the requests/sec and the pages/sec to be the same.
Looking for answers on the internet we found that the page time is the sum of all requests to display a page. This includes css, scripts, images, … That is why some people have a high request/sec and slower page time. But we have a REST service, there are no other requests made but the main request for the resource. What is going on here?
My colleague Stefan helped me with troubleshooting. We came up the following explanation;
One of the properties of the run settings is the number of pages/urls to report, [Maximum Request URLs Reported]
This number is 1000 by default which is way less than the 100000 unique requests we do during the load test,
The 1001st and later requests are combined in a “other request urls” group and it looks like this is the group used on the summary report,
Thesis: Pages/sec is the average number of requests made to the “other request urls” during the load test
We put the thesis to the test using the formula below. Since the numbers are very high and we use averages, we can assume that slow and fast resources are of little impact on the end result.
(Total tests / Count of Other Request Urls) * Pages per sec = Requests per sec
After doing several test runs we found no results that prove the formula wrong. Just to be safe we changed the [Maximum Request URLs Reported] property to zero. This means no urls get logged and the pages/sec is also zero.
Nothing to see here, carry on!