Wednesday, June 26, 2024

Load Testing

Load testing is the process of putting demand on a software system and measuring its response. Load testing is performed to determine a system’s behavior under both normal and anticipated peak load conditions. It helps to identify the maximum operating capacity of an application as well as any bottlenecks and determine which element is causing degradation.

Load testing is used in different ways.

*Multi-user systems

Load testing generally refers to the practice of modeling the expected usage of a software program by simulating multiple users accessing the program concurrently. As such, this testing is most relevant for multi-user systems, often one built using a client/server model such as web servers. As an example, a web site with shopping cart capability is required to support 100 concurrent users broken out into following activities:

  • 25 virtual users log in, browse through items and then log off
  • 25 virtual users log in, add items to their shopping cart, check out and then log off
  • 25 virtual users log in, return items previously purchased and then log off
  • 25 virtual users just log in without any subsequent activity

A test analyst can use various load testing tools to create these virtual users and their activities. Once the test has started, the application’s performance can then be monitored and captured.

*Other types of software systems

For example, a word processor or graphics editor can be forced to read an extremely large document or a financial package can be forced to generate a report based on several years’ worth of data.

Statistics that will be analyzed include the CPU, memory, disk IO of the physical servers and the response time.

Possible causes for slow system performance include, but not limited to, the following:

  • Application servers or software
  • Database servers
  • Network  latency, congestion, etc.
  • Client-side processing
  • Load balancing between multiple servers

User experience under load test

In the example above, while the device under test (DUT) is under production load - 100 VUsers, run the target application. The performance of the target application here would be the User Experience Under Load. It describes how fast or slow the DUT responds, and how satisfied or how the user actually perceives performance.

Browser-level vs. protocol-level users

Historically, all load testing was performed with automated API tests that simulated traffic through concurrent interactions at the protocol layer (often called protocol level users or PLUs). With the advance of containers and cloud infrastructure, the option is now present to test with real browsers (often called browser level users or BLUs). Each approach has its merits for different types of applications, but generally browser-level users will be more akin to the real traffic that a website will experience and provide a more realistic load profile and response time measurement. BLUs are certainly a more expensive way of running tests and cannot work with all types of applications, specifically those that are not accessible through a web browser like a desktop client or API-based application.

Load testing tools


Tool name

Company name

License

Pricing

Notes

Apache JMeter

An Apache Jakarta open source project

Apache License

Free

Java desktop application for load testing and performance measurement.

LoadRunner

Micro Focus

Proprietary

Trial available

Primarily used for executing large numbers of tests (or a large number of virtual users) concurrently. Can be used for unit and integration testing as well.

loadUI

SmartBear Software

EUPL

Demo available

Cross-platform load testing tool, targeted mainly at web services. Integrates with soapUI.

Share:

0 comments:

Post a Comment

Translate