Sunday, November 18, 2012

Overview Performance testing


Performance Testing is a combination of 3 type of Testing:
          – Performance test
          – Load test
          – Stress test

Performance test: Need to know at least two things:
       Expected load in terms of concurrent users or HTTP connections.
       Acceptable response time.è Goals: You want to make sure your code runs as efficiently as possible and your database is optimized on a given OS/hardware configurations.

Load test:
          Load testing as part of the process of performance testing and tuning
          Load testing is sometimes called volume testing, or longevity/endurance testing
è Goals: Expose bugs that do not surface in cursory testing, such as memory management bugs, memory leaks, etc.Ensure that the application meets the performance baseline established during performance testing. This is done by running regression tests against the application at a specified maximum load.

Stress test:
          Stress testing tries to break the system under test by overwhelming its resources or by taking resources away from it (in which case it is sometimes called negative testing)
ð  The main purpose behind this madness is to make sure that the system fails and recovers gracefully.

 Differentiation between P&L&S:
Performance testing and load testing can seem similar, their goals are different



Example: Yahoo has a website. We know that million of people are going to access this site every day. 
In fact thousands will be clicking this website at same movement of time. But Yahoo has limited hardware capability. Now they want to know how many people can access their website (hitting their servers) at the same time.

1. Load testing - is expected rate is matched? Yahoo estimated that a maximum of 90,000 people (example) can hit at any point of time. So load testing is performed that whether with 90,000 virtual users system is performing well or not?

2. Performance testing - Suppose with one user yahoo page opens in 1 sec. Then with 1000 users is it opening in 1 sec? then with 50,000 users hitting website at same time, is it opening in 1 sec....so what is performance of website up to a desired level? (up to 90,000 in this example)

3. Stress testing - if we slowly increase users from 90,000 to say 91,000 then to 92,000 then to 93,000 and so on...then at what time servers crash or site stopped responding? 

Determining Acceptable Response Time or Acceptable User Experience
Factor : The customer’s value system expectation


Performance Testing Key Factors
Performance testing involves the evaluation of three primary elements :
          Workload
          System environment and available resources
          System response time
Workload: Workload is the amount of processing and traffic management that is demanded of a system.
          Three elements be considered :
          - Users
          - The application
          - Resource
     System Environment and Available Resources:
          There are three primary elements that represent the resources involvement in any online transaction :
          -A browser on the client-side
          -A net work
          -Server-side

NOTIONS
          Running Vusers
          Hits Per Second Graph
          HTTP Responses per Second Graph
          Throughput Graph
          Transaction Summary
           Average Transaction Response Time

Running Vuers
This line graph shows the impact of Ramp-Up and Ramp-Down specified for run-time. This also shows the time when Errors begin to occur during the test run.


Hits Per Second Graph
The one line on this graph helps you evaluate the amount of load Vusers generate, in terms of the number of hits to all web servers. It displays the number of hits made on all Web servers by Vusers during each second of the load test.


HTTP Responses per Second Graph
The HTTP Responses per Second graph shows the number of HTTP status codes—which indicate the status of HTTP requests


Throughput Graph
This line chart helps you to evaluate the amount of load Vusers generate on network resources. It displays the raw amount of bytes that the Vuser client received each second as a result of the hits on the web server during load testing.


Transaction Summary
This bar graph displays, by transaction action, how many transactions passed, failed, stopped, or ended with errors


Average Transaction Response Time
This line graph is used to determine whether performance is within acceptable minimum and maximum transaction performance time ranges expected of the system. It displays the average time taken to perform transactions during each second of the load test.










No comments:

Post a Comment