concept database in category algorithms

This is an excerpt from Manning's book Algorithms and Data Structures in Action.
Calling the database every time you need to check an email address against your contacts list is out of question: you are stuck with this legacy machine that can’t scale up, and you didn’t get funds for refactoring and scaling it out[2]. Your DB could not support more than a few calls per second, and your management’s projection is in the hundreds of emails written per second (they are very optimistic, and a bit reckless, but let’s not worry about that for now!). Your first instinct would be to ask for a remote distributed cache, like Memcached, Cassandra or Redis. A roundtrip to the cache server alone would take in the range of a hundred milliseconds, best case scenario, which would be good. But neither spinning up a new server for the cache, nor buying it as a cloud service could be feasible for you, budget-wise.
Number crunching is not the only context in which optimizing your computation matters. If we move to web applications, for example, one of the costliest operations is certainly accessing a database, and even more if it involves iterating through a cursor to count or compute something.