What is Workload?
Performance Test Workload refers to the distribution of load across the identified scenario. The performance tester prepares a workload to simulate the real-world situation in the performance test environment. In the performance testing cycle, different workloads are created to study the behaviour of the system under various loads and conditions. Sometimes the workload is also known as a scenario.
What is Workload Modelling?
The process of creating a performance testing scenario with the help of non-functional requirements and performance test scripts is known as Performance Test Scenario creation or Workload Modelling.
Purpose of Workload Modelling:
- Workload Modelling helps to generate the expected production-like conditions in the performance test environment to check the true performance of the application.
- Another purpose is that when there are some production performance issues detected in the live environment then workload modelling helps to replicate the same condition to reproduce the issue in the performance test environment.
Performance Test Analyst or Engineer (designation may vary as per company policy) has a responsibility to prepare the performance test scenario exactly the same as mentioned in the Performance Test Plan.
The designing of the workload comprises various calculations but the ultimate aim is to achieve the desired goal in various terms. These terms could be the number of users, transactions per second, hits per second, throughput etc. The workload model helps to design a predictable (stress test), repeatable (regression load test), scalable (stress/breakpoint test) and sustainable (endurance test) scenario. Before designing a workload model, it is important to collect all the relevant information which helps to create an effective workload model. Such information is available in the Performance Test Plan.
The first thing to check is how many types of tests are mentioned in the performance test plan. Each type will have a separate workload model. For example, the user count in the load test is lesser than the user load in the stress test. Hence both will have separate workload models or scenarios.
Now, collect the respective metrics for all the identified scenarios. The list of workload metrics is:
- Number of Users
- Iteration per hour
- End to End Response Time (Iteration Response Time)
- Number of Transactions
- Think Time
- Hits (Requests) per second
- Individual page response time
Does a performance tester need all these metrics to design a scenario?
No, to make it easy, understand the category of the workload metrics:
- Number of Users (Basic)
- Iteration per hour (Basic)
- End to End Response Time (Calculative + Targeted)
- Number of Transactions (Calculative)
- Pacing (Calculative)
- Think Time (Calculative)
- Hits (Requests) per second (Targeted)
- Throughput (Targeted)
- Individual page response time (Targeted)
It is not worth saying that basic metrics cannot be targeted. The purpose to divide all the metrics in the category is to provide a basic understanding of the workload model. The advanced level of workload will be discussed later.
In order to design a basic workload model, 2 metrics are very important. The performance test plan must have the value of these two metrics:
- Number of User Load: The expected user load on the server during the test.
- Iterations per second: How many iterations a user needs to complete in the test duration.
What about the other metrics? The other metrics are either calculative or targeted. Refer to the next post to understand the calculation of other metrics.
A Performance Tester creates and delivers the performance test scenarios at the end of this phase. These scenarios can have names like Load Test Scenarios, Stress Test Scenarios and so on.
The example of workload modelling is itself a big topic. Refer to the next post to get a practical understanding of Workload Modelling/Scenario creation. So, keep continuing the learning.