- examine server and thread counts - check the ratio of front-end to back-end servers along with the number of threads each side can
handle, in production vs. QA.
- stress both sides of an interface - make sure the back-end can handle sudden bursts of traffic and make sure the front-end can deal
with slow or dropped calls.
Friday, April 2, 2010
Release It! - Chapter 4.8 Unbalanced Capacities
If one layer has more capacity than a layer it calls into, it can overwhelm it. It is probably impractical to have each layer supplied with similar capacities but you can make some design decisions to help deal with the situation. The front-end can use Circuit Breaker to relieve pressure on the back-end when things get slow. The back-end can use Handshaking to notify the front end to throttle back its requests. You can also use Bulkhead to reserve capacity on the back-end to deal with other transaction types. QA usually doesn't have the budget for lots of servers so Unbalanced Capacities is usually not detected during normal testing. Using a test harness that can mimic a back-end system struggling under load can help to verify that the front-end system can degrade gracefully. On the back-end try and do some analysis to see exactly how unbalanced things might get. Stress test your back end with loads that approach the front-end's maximum capacity -- and pick an expensive transaction. The back-end should slow down but should be able to recover once the load returns to normal.