allengeorge/libraft — pull request #44 by allengeorge (2014-04-08 03:02:19+00:00)
Title: Add methods to load and store snapshots

Snapshots:
- Create a base interface 'Committed' and use it represent
snapshots and committed commands.
- Change applyCommand -> apply and
getNextCommittedCommand -> getNextCommitted. Both methods now
return either snapshots or commands.
- Define a SnapshotStore interface for the snapshot-storage subsystem
- Define interfaces to be implemented by SnapshotStore implementations
for representing snapshots and snapshot-requests
- Create a disk-based implementation for SnapshotStore
- Define new properties for configuring snapshot storage
- Add unit tests to test snapshot loading, storing, use and configuration
- Support snapshot load/store in KayVee

RaftAlgorithm:
- NOOP LogEntries are now exposed to RaftListener implementations
and to callers of getNextCommitted. These entries simply
advance logical time, but make to changes to a user's replicated
state
- Add a getFirst() method to Log

Miscellaneous:
- libraft now requires Java 1.7+ to compile
- JDBI is used in libraft-agent
- H2 and SQLite3 are used in libraft-agent tests
- All exception classes now define serialVersionUID
- All KayVee classes have full Javadoc
- Improve KayVee test coverage

Resolves #25, #32.