As with a lot of IT terms, latency budgets can be used in a multitude of ways. In this case, we refer to the maximum time allowed for a call.
Translating that into our current refactoring, it refers to two things:
- The maximum time allowed for the upstream (database or exchange rate service) call to complete
- The maximum time allowed for our register API to complete
You can see how these two things are related. Let's look at how our API response time is made up:
API response time = (exchange rate service call + database call + our code)
Assuming the performance of our code is mainly consistent, then our service quality is directly dependent on the speed of the upstream calls. This is not a very comfortable position to be ...