Most recent edit on 2011-10-21 14:11:21 by Admin
Edited on 2005-11-27 02:15:23 by Admin
Edited on 2005-11-23 10:26:53 by RolandStens
- Weighing Performance versus Maintainability
Edited on 2005-11-23 10:01:22 by RolandStens
- J2EE: Performance Patterns and Techniques∞.
- J2EE Performance Patterns and Techniques∞.
Database Performance Patterns∞.
Oldest known version of this page was edited on 2005-10-24 14:16:54 by Roland Stens 
: a pattern is a common solution that appears in many different contexts.
- Captures expert knowledge.
- Solves ?reinventing the wheel.?
- Identifiy abstractions.
Performance patterns: higher level than design patterns.
- Some things are done more often than others, so streamline these operations (i.e. shorten the critical path).
- Defer other operations if possible.
- Other Benefits
- Spreads the load out in time, or avoids it altogether.
First Things First
- Be sure the fast path is the actual path being used!
- Things which matter most should never be at the mercy of things which matter least. (Goethe)
- Same as in time management: prioritize!
- This only works if overloads are temporary.
- Make the interface match the application. (Especially for distributed applications as RPC calls are expensive!)
- batch up requests into one call.
- A new application may have a lot of churn.
- Combine multiple similar requests into one big request.
- Overhead of processing requests is amortized over the batch.
- Reduces overall demand.
- Batching infrequent requests will cause unnecessary delays.
- Batching itself may cause more delays.
- Spread demand for high-usage objects spatially.
- partition the data.
- route requests to different processes.
- If all requests take the same route, you?re no better off.
- Spread the demand temporally.
- i.e. Run jobs later when there is less demand.
- Or, run them ahead of time and save results.
- Lower queueing delays overall.
Slender Cyclic Functions
- May actually increase total demand.
- (common in embedded real-time systems).
- Minimize the time spent in periodic functions.
- Push as much processing as possible into non-time-critical functions.