Visual Studio 2017 Load Testing of an Azure Web App with Application Insights Part 1 of 2

I set out a personal weekend hack-a-thon to do a load test on a Single Page App I had built many years ago. This app is hosted on Azure App Service and Azure SQL DB. My experiment was to see if I can simulate 10,000 and observe the effects of the load on a small pricing tier. I will share my approach, challenges, tips and what I’ve learned in the 2 days.

My Lab Environment Specifications

App Service Plan

Scale Up/Pricing Tier: I1 1 Core 3.5GB RAM

Scale out:

  • 1 instance (initial default)
  • Auto Scale Configuration

When the average CPU utilization is > 25%, I have set it to scale another instance in the App Service Plan. For the purposes of the demo, I set low and easy to reach thresholds for ease of testing. However for world scenarios the threshold would be approximately  >  75% to 85%.

For more details on autoscale read the article

As a side note, this App Service Plan is configured as part of an App Service Environment(ASE). This has no intended purposes for load testing. It is an isolated and dedicated environment from a virtual network point of view.

Azure App Service Web App

The following is a high level overview of the application design and how Application Insights is leveraged.

  • Single Page Application using KnockoutJS, JQuery, Bootstrap and ASP .NET MVC
  • Application Insights configuration


Application Insights

Provides monitoring of the associated App Service. I have been using this for a few years and over time there have been many improvements and new features. The features I use most often are

  • Live Metrics Stream for real time monitoring
  • Performance to see operations per second
  • Servers to see resource usage metrics
  • Browser to see client-side metrics with the App Insights JavaScript SDK
  • Users to see each user metric, but you need to configure and track a unique ID of the users


Azure SQL Database

  • Pricing Tier: Standard 10 DTU
    The price is around $22CAD / month.

So what is a DTU?
A DTU is “blended measure of CPU, memory, I/O (data and transaction log I/O). The ratio amongst these resources was originally determined by an OLTP benchmark workload designed to be typical of real-world OLTP workloads.”


Visual Studio 2017 Load Test

My Load testing environment is setup on an Azure Virtual Machine with size of Standard F4s (4 cores, 8 GB memory). You must have enterprise edition and a license to be able to do load test of simulated users greater than 250.

Visual Studio Load Test Project

  • 3 IE browser based recorded web tests. That is recording my clicks as I interact with the web app.
  • Load test using these 3 web tests with 1/3 distribution each. A web test will be run by a simulated user.
  • The user load pattern starts with 1500 simulated users and for every 20 seconds, 250 users will be added to a max of 10,0000 users. The load test duration is set for 15 minutes.

To see detailed instructions on setting up a load test read the following:

To see the load test execution, the metrics observed and my commentary, read the next blog post Visual Studio 2017 Load Testing of an Azure Web App with Application Insights Part 2 of 2

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s