Tuesday, December 14, 2010

Basics , definitions and directions

What is software performance?Software performance is a measure of three kinds of metrics
Latency/Response Time/ Round trip Time etc. This basically means how fast is your software, for example, how fast does your website's home page load on a browser connected to broadband network, or how quickly can your software service complete an operation (for example how quickly does your blog post get published once you click the publish button).


Throughput/Bandwidth: How many concurrent operations can your service (applied more to services) process at the same time. Example how many users can be active on facebook at the same time, or how many users can send an email at the same second in yahoo mail or how many people can search for some reality show star on google at the same time... (this limit is usually crossed by DOS attack).


Efficiency: How efficiently does the software use the resources available to it while working at its peak load. Resources available to a software include local machine resources ( the machine on which the software is hosted) or resources available over a network. Example how much disk space is used by youtube.com to host the latest cute kitty video. Or how much memory is used by the Browser favuorites service to serve 250 million windows live users.


Why is software performance such a big deal?
Firstly and obviously users (= money) like fast software, whether it be a web service or spread sheet on the desktop.
Secondly, and this is not one that everyone thinks about, better performance often means more optimized resourse usage, hence it lowers the cost to serve for software services.Example, facebook.com would make lot more money if they could reduce the number of servers hosting the facebook service by 5%. Remember, cost to serve is a very important to managers, and you can use this to make them see why software performance is such a big deal.


What is performance testing?
Performance testing is the process of measuring software performance, it involves the following:
1. Very Important: Having performance goals.
2. Simulating the correct conditions under which to test software, this includes loading the right amount of data, having the correct amount of load, and the correct conditions (e.g. network latencies , important for web site performance).
3. Collecting performance information (like logs, ETW traces, profiler traces etc)
4. Analyzing collected information and validating the performance against goals.


There are a lot of terms thrown around in the performance testing field and before I talk further it would make sense to try and define a few most common ones.
Definitions:
Stress Test: Testing a piece of software by incresing the load on it (example number of concurrent users) till the software starts failing.
Stability Test: A performance test that validates how long can a service run without crashing under normal load expected in the real world.
Availability: is defined as a measure of how available a software service is.
Reliability: is defined as a measure of how reliable a software service is.
The difference is a service can be available 100% of the time but might only return a valid response 50% of the time. Think of availability as a measure of 404 error in http, where as reliability a measure of 500 erroc code in http.
Resource Leak: This happens when resources used by the software are held on to even when they are no longer being used. Examples include memory leaks, thread leaks etc.




Directions:
The rest of this blog is going to talk about specific topics on performance testing, some basic and some advanced but all interesting.

1 comment: