Site Reliability Engineering, 2nd Edition
by Betsy Beyer, Chris Jones, Christof Leng, David Huska, Jennifer Petoff, Niall Richard Murphy
Appendix E. The Mathematics of Composing SLOs
When composing SLOs, you can use a statistical model to calculate the best possible availability of your service based on the availability of its dependencies. This model is determined by the architectural pattern used to call the dependencies.
Serial Dependencies
In a serial dependency chain, a request succeeds only if all calls in the sequence succeed.
Assume you have a Service A that calls Service B and then Service C. Their availability SLOs can be stated as probabilities of failure:
-
Service B has 80% availability, so its failure probability is
-
Service C has 90% availability, so its failure probability is
Assuming their failures are statistically independent, the probability of a successful call to Service A is the product of the success probabilities of its dependencies:
Plugging in our numbers:
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access