- loadtest <> stresstest:
- loadtest: test user experience
- stresstest: find when the application breaks
- performance anti-patterns & solutions:
- lack of stress testing → introduce a stress test harness
- repeatable test
- control load
- shot in the dark: fix ugly code
- ugly code runs just fine
- measure, don't guess!
- lack of stress testing → introduce a stress test harness
- Apache JMeter → root node: “Test Plan”
- Thread Group
- set looping / # threads
- HTTP Request
- → variables: ${var}
- defeat cache
- vary testdata
- → variables: ${var}
- Timer child for think-time→ e.g. Uniform Random Timer
- aggregate report
- view results tree → captures data of requests: e.g. don't measure 404 errors
- Thread Group
- understand the environment, identify dominating consumer → look at the full system
- actors: usage patterns
- application
- locks
- external systems
- jvm/os
- memory
- hardware management
- tools e.g.:
- vmstat on hpux
- jps
- jstack
- visual vm (thread and heap dumps)
- hardware
- cpu
- memory
- disk I/O
- network
- response time budgets:
- detail the time of the different components → add customizable time measures
- database
- application server
- client
- detail the time of the different components → add customizable time measures
- common problems, demo's:
- poor response times, low cpu
- thread pools
- locks
- → VisualVM, thread dump + plugin thread dump analyzer, identify lock
- poor response times, low cpu
2009/11/19
Devoxx 2009: The not so Dark Art of Performance Tuning
19/11/2009, Kirk Pepperdine & Dan Hardiker
Labels:
Devoxx,
devoxx 2009,
java,
jmeter,
performance,
programming
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment