How to Manage Performance Engineering in Agile Projects:
- New Challenges in Web 2.0 Applications
- Performance Space in Agile Process
- Performance Engineering Activities
- A Case-study
2. Abstract
Web 2.0 New Challenges
Performance Space in Agile Process
Traditional Performance Engineering Activities
Performance Engineering Activities in Agile
Exploring Opportunities
Performance Measurements
Findings and Recommendations
Conclusions
STC 2011 2
2
3. New Challenges in Web 2.0 Applications
Requirement
Provide improved user experience
Rich and interactive UI elements
Social interactivity: publish and share contents, events
Pull contents from several portals to provide customized pages
Using third party controls and libraries for quick implementation
STC 2011 3
3
4. Performance Space in Agile Process
Development Characteristics
Short development Cycles
Focused on Product Backlog
Performance Engineering Challenge
User stories are not available to set
the Performance goals for sprints
No Check leads to Poor Quality Artifacts
Hawthorne Effect*
The Broken Window theory**
* http://en.wikipedia.org/wiki/Hawthorne_effect
STC 2011 ** http://www.codinghorror.com/blog/2005/06/the-broken-window-theory.html
4
7. Exploring Opportunities
Optimization Opportunities
Minify JavaScript
Cache static resources, set appropriate expiry
Compress datasets (XML, JSON). This needs extra CPU cycles.
Configure Etags
Baseline component performance
Check the response time, throughput, latency with different loads
Check DB related requests for their responses
Monitor CPU, memory, connection pool, disk I/O
Find result set paging opportunities
Identify requests to third party components/servers
STC 2011 7
7
9. Load Plan
Total number of Virtual users: 20
Number of Virtual users per batch: 20
Batch Ramp up time: 10 min
Think time: Normal Distribution Pattern [Application specific
parameters]
Number of Iterations: 15
STC 2011 9
9
10. Page Response vs. User Load Time
CPU: 2.66
GHz dual
core
RAM: 2 GB
Windows
2K3 server
STC 2011 10
10
11. Web Processor Utilization vs. User Load
CPU: 2.66
GHz dual
core
RAM: 2 GB
Windows
2K3 server
STC 2011 11
11
12. W3wp – Private Bytes vs. User Load
CPU: 2.66
GHz dual
core
RAM: 2 GB
Windows
2K3 server
STC 2011 12
12
13. Findings and Recommendations
The application appeared to be non scalable as the response time
increases linearly with user load
It was found that there were some un-optimized queries
Memory leaks were detected in a particular library
Further code profiling was recommended
Memory Dump Analysis revealed high frequency of GC.
It was observed that large size objects were getting disposed. This is
being optimized.
STC 2011 13
13
14. Conclusions
Performance Testing process in Agile Methodology brings in a change
in “Attitude of team”
Though there are no clear performance goals in a given sprint, the
system bottlenecks are constantly checked
The issues are known and fixed much earlier in the dev cycle
This results in a robust application as the application is benchmarked
across its different features
The benchmark data provides crisp pointers for capacity planning
However, this does not do away the need for Load testing on
Realistic Production Environment.
STC 2011 14
14
Broken Window Theory: If a building has a broken window that is left unrepaired, its chances of further vandalism are increased.
This graph represents the Page Response Time vs. User Load. Besides being on higher side, the page response time appears to be increasing drastically with small increase in the user load.The system gives oscillatory response while there is max user load of 20.This graph is exhibition of poor efficiency and scalability.
This graph represents the web server processor utilization vs. user load.As the user load increased the processor utilization also increased linearly till the user load reached to around 12. After that the processor utilization appears to be consistently averaging out to around 45% and then it drops as the user load ramps down.This graph represents that the processor utilization is within the acceptable bounds.
This graph represents the IIS’s worker process (w3wp) private bytes allocation vs. user load.As shown in the graph, the private bytes allocation goes on increasing over the entire span of test execution. The allocated memory was never released.The linear increase in the private bytes allocation with time indicates the memory leakage.