How to distribute stress in load testing scenarios?

One of the challenges in load testing is planning and deciding which user activities to include and how to mix different usage scenarios. Our earlier post how to plan realistic load test scenarios provided some tips for identifying user transactions. But assuming you’ve past that stage, the next question is how to decide about the proportion between different activities ?

Let’s use a practical example. Assume you’re testing an ecommerce site. Your load scenario would probably simulate the activities related to the entire website – product pages, search, store page, checkout process, cart and payment. But how do you know how to distribute the load between these different areas? Which proportion of the full scenario should be dedicated to product pages vs. the search functionality?

stress

Assume you dedicate 10% of the scenario to product search, since this is the average number of users who perform this action on the site. But what if this assumption is wrong and there are more searches done, and in fact only when changing the proportion of the search load to 15% do problems start surfacing? While the 5% increase seems negligible, you’re actually increasing the load placed on the database searches by 50%. If the backend database is indeed a sensitive link, then it might easily affect the entire application stability. But it must be stressed sufficiently for its weakness to be discovered. Put differently, if you don’t place enough stress in the right places then your load scenario will simply not achieve its purpose.

What can you do about this? Obviously, you should always load your system with more users/stress than your ‘raw’ planning data. But in addition, you should also try modifying and increasing/decreasing the proportions between different transactions. Your job as a performance engineer is to test the unexpected and identify the locations or scenarios where an increased stress ‘breaks’ your system. What’s your experience with this?

WebLOAD was designed to address this issue, letting you define the weight between different activities. You can learn more here.