A Java library to perform snapshots in a distributed environment using the Chandy-Lamport algorithm. The backend maintains a mesh network topology of the nodes connected.
All the code of the library is commented following the javadoc directive to allow for an easy use of the project.
A demo is also provided in the form of nodes exchaning oil to each other. The state of the nodes is the current oil amount present.
- Run maven:
- clean
- package
- Execute the obtained .jar on each machine
- The basic steps to get a node up and running are:
- initialize, myHostname, myPort, initialOilAmount
- join, gatewayHostname, gatewayPort
- then you can take a snapshot, restore or disconnect