Performance validation is the process of ensuring that your application meets performance requirements now and in the future. You test your application, determine whether it meets requirements, and, if it does not, look for ways to tune the performance. Performance requirements are rarely met without some tuning so you need to consider performance throughout the development life cycle. Considering performance does not mean micro-optimizing every component, however.
Realize that what's important to the users of your application is overall system performance, not the performance of each individual component. Distributed applications have a lot of variables that can influence performance—hardware, communications links, system software configuration, application topology, and so on—regardless of how your components and applications are coded. (See Chapter 14 for more information about choosing an application topology.) There will always be a trade-off between ease of development, deployment, maintenance, and performance. The key to performance tuning is to do the minimal amount of work required to identify and eliminate—or at least reduce—bottlenecks in the overall system so that your application meets its performance requirements.
During performance validation, you will rarely be able to exactly duplicate the conditions in which your application will be deployed, especially early in the development life cycle. Thus, validation is a matter of extrapolating expected performance from the results of a series of controlled tests in environments resembling the deployed environment. The more closely the test environment resembles the deployed environment, the more confidence you can have that your application will meet performance requirements. However, the effort involved in creating such a test environment can greatly outweigh the reduced risk that your test results might be incorrect. Again, the key is to do only as much work as necessary to meet your goals to an acceptable degree of confidence and then stop. Performance validation is all about reducing the risk that your application will not achieve a necessary level of performance, not about tuning the application to the ultimate level of performance.