Load Testing with Badboy

A key part of validating your web site is to know not just how it behaves when you alone are using it, but how it behaves when a large number of people are accessing it all at once. This is generally known as "load" or "stress" testing. Badboy offers some highly useful features to help you do this kind of testing.

Threads

In order to understand Badboy's load testing features it is important to understand the concept of "threads". The term "thread" is borrowed from computer programming and simply means a separate virtual instance of Badboy executing your script. For example, if you have five threads running then it is as if you had five separate copies of Badboy running, all executing your script - just like threads in a cloth, all the threads run in parallel, doing the same thing. Each thread creates an additional unit of load on your server, simulating the effect of one or more users navigating your web site.

Thread Items

Badboy makes it easy to create Threads as part of your script by using Thread Items. Thread Items play as part of your script, but they behave a bit differently to normal items. Instead of directly executing the items they contain, Thread Items instead create "virtual", invisible Badboy instances and use those to play the items underneath them in the script. Each such thread executes as if one user was browsing, creating additional load on your web server.

The figure below shows how a Thread Item looks in your script:

Thread Item

Continue reading the following topics for more information on Thread Items:


Badboy Documentation Generated on Mon Dec 29 22:28:42 EST 2008