Architecture
Interface
- How users interact with the database
- Includes all CRUD operations
- Can do other stuff
Execution
- Controlled by the interface
- Commands are optimised
- It manages the transactions
- Also manipulates data sent back from storage
Storage
- Stores the data
C.A.P Theorem
Distributed systems cannot be all three:
Consistencymeans that all nodes in a distributed system view the same data at the same time, ensuring a single up-to-date copy of the data. (cant be available if selected)
Availabilityensures that all requests receive a response, whether it's success or failure.
Partition tolerancemeans that the system will continue to operate even if there are network failures causing some of the nodes to be isolated.
According to the theorem, it is impossible for a distributed data store to simultaneously provide more than two of these guarantees. That means, in the event of a network partition, one has to choose between consistency and availability.