Designing Data-Intensive Applications
Key points
Throughput -> The number of records we can process per second
Response Time -> The time between a client sending a request and receiving a response. This is the time the client sees, including network and queueing delays.
Bottlenect ->  a bottleneck occurs when a single component limits the capacity of an application or a computer system. The bottleneck has the lowest throughput of all parts of the transaction path.
Latency ->  It is the duration that a request is waiting to be handled during which it is latent, awaiting service.
SLO -> Service level objectives
SLA -> Service Level Agreements
Head of line blocking ->. When several backend calls are needed to serve a request, it takes just a single slow backend request to slow down the entire end-user request. If an end-user request requires multiple backend calls, and so a higher proportion of end-user requests end up being slow which leads to tail latency amplification.

Common functionality of data-intensive apps
- Databases
- Caches
- Search indexes (allows users to search data by keyword or filter)
- Stream Processing (handle asynchronously)
- Batch processing 
Reliability
- The system should continue to work correctly (performing the correct function at the desired level of performance) even in the face of adversity (i.e. hardware or software failures or human errors)
- Ex: Netflix Chaos Monkey 
		A tool that randomly disables our production instances to make sure we can survive this common type of failure without any customer impact.
Scalability
- As the system grows (in data volume, traffic volume, or complexity), there should be reasonable ways of dealing with that growth.
- Load can be 
    - Requests for second
    - Ratio of reads to writes on databases
    - the no of simultaneously active users 
    - the hit rate on the cache
Maintainability
- Over time, many different people will work on the system( engineering and operations, both maintaining current behaviour and adapting the system to new use cases,) and they should all be able to work on it productively.
