Refactoring yet again. Added support for minimal durability state
working on unit tests for refactored code
converted heartbeat.py to functional.py and updated unit tests
Converted code to essential, practical, and functional modules. Updated unit tests. Cleaned up documentation