Simple examples of operating system, distributed system and database system concepts in python
Demonstration of how two phase commit protocol works in distributed system: TwoPhaseCommit.py
MVCC.py
Read only scan on the list is lockless. It use the timestamp to read the latest version.
Other operations acquire lock. Write operations perform Copy-on-Write.
Oversimplified examples of the common appoaches to solve crash-consistency problem
Journaling a.k.a Write Ahead Logging (WAL) : JournalingFileSystem.py
CopyOnWrite (COW) : CopyOnWriteFileSystem.py
Using monitor and semaphore to solve Bounded Buffer problem, Dining Philosopher problem and ReaderWriter problem
BoundedBufferMonitorSolution.py
BoundedBufferSemaphoreSolution.py
DiningPhilosophersMonitorSolution.py
DiningPhilosophersSemaphoreSolution.py
ReaderWriterSemaphoreSolution.py
Using pipe, messagePassing and shared Memory are three common approaches of interprocess communication
pipeIPC.py
messagePassingIPC.py
sharedMemoryIPC.py