Tasked with setting up a performance test for an n-tier distributed system? Before you get started, check out these tips on creating a test environment.
This is the first article in a two-part series that will discuss procedures for analyzing the performance of an n-tier distributed computer system. In part one, we examine components of a test environment and show you how to create a test matrix. The follow-up article will detail test procedures, bottleneck analysis, and how to establish system benchmarks for performance comparison.
It is important to realize that software performance testing is a process-intensive set of tasks, and the more time you spend on proper setup, the better your chances of pocketing meaningful data that is essential for system design and architectural scaling.
Know your testing environment
In testing, it’s crucial that you mimic your production system. For example, if you’re trying to collect performance data on a machine where developers are running large compiles several times an hour, chances are the data you collect will be irrelevant. The same can be said if your test machines are connected to a network where someone is hosting a public MP3 collection.
However, exact replication of your production environment, including all hardware and software, could be cost-prohibitive. Within the constraints of your budget, re-create the “live” environment as much as possible.
A well-engineered test environment will make it easier to spot particular issues, such as poorly configured applications and unacceptable throughput. More important, a test system that mimics a production environment provides a foundation for quality test data. It is this data that will be used for performance benchmarking and capacity planning. Part two of this series will deal with these topics in detail.
Here’s what you will need
To set up your testing environment, you’ll need the following components:
Make a test matrix
When you delve into your distributed application, you need a systematic method of organizing the large number of parameters affecting performance. Protocol options, transaction sizes, parameters passed to the application, even application configuration settings can all affect performance. How do you keep track of it all?
Perhaps the most important step in performance analysis is building a test matrix to capture all of the dimensions that have an impact on your system’s performance. Begin by creating two columns, one for dimensions and another for values. Then, list all of the dimensions that affect performance for the whole system, each function in the system, each subfunction, and so on. Ultimately, this matrix will serve as a top-level overview of the system and allow you to develop smaller matrices for test plans and system documentation.
Figure A shows a simplified test matrix for a document translation Web service that converts a Word document to XML and vice versa.
Figure A
|
||||||||||||||||||||||||
Test matrix for a document translation Web service
In Figure A, eight dimensions are listed. Each dimension possesses a large range of values. The next step is to expand this matrix by determining which of these dimensions should be tested against each other. In our example, authentication and conversion type are not related, but message size and conversion type are. (See Figure B.)
Figure B
|
Message size and conversion type
Obviously, complex systems will require more intricate test matrices. These matrices expand to several pages with 20 to 30 columns, demanding considerable test time. Use the matrix to outline potential issues to developers as well as to senior management.
Proper planning can make the difference between meaningful test results and a collection of useless data. In this article, we’ve taken a look at the components of a high-quality test environment and shown you how to implement a test matrix. The next installment discusses creating a thorough test plan, deciding what to include in the testing process, and establishing performance benchmarks.