Commit Graph

13 Commits

Author SHA1 Message Date
Wyatt
47b744f1c0 ipfs-cluster-service state upgrade cli command
ipfs-cluster-service now has a migration subcommand that upgrades
    persistant state snapshots with an out-of-date format version to the
    newest version of raft state. If all cluster members shutdown with
    consistent state, upgrade ipfs-cluster, and run the state upgrade command,
    the new version of cluster will be compatible with persistent storage.
    ipfs-cluster now validates its persistent state upon loading it and exits
    with a clear error in the case the state format version is not up to date.

    Raft snapshotting is enforced on all shutdowns and the json backup is no
    longer run.  This commit makes use of recent changes to libp2p-raft
    allowing raft states to implement their own marshaling strategies. Now
    mapstate handles the logic for its (de)serialization.  In the interest of
    supporting various potential upgrade formats the state serialization
    begins with a varint (right now one byte) describing the version.

    Some go tests are modified and a go test is added to cover new ipfs-cluster
    raft snapshot reading functions.  Sharness tests are added to cover the
    state upgrade command.
2017-11-28 22:35:48 -05:00
Hector Sanjuan
4ea1777050 Fix sharness tests
Use docker to run ipfs
Improve intialization of daemons
Fix a bunch of tests
Improve run script
Make sure everything is shell-compatible (remove bash syntax)
Fit to run in travis
2017-07-21 11:24:17 +02:00
ZenGround0
99217ea84e Travis sharness (#110)
* Added travis sharness build

* ipfs-cluster-ctl help text width overflow fixed

* Expect success from fixed sharness test

* First travis-sharness PR touch up
Undoes gx rewrite of cluster-ctl dependencies
Undoess linebreaking of usage descriptions
Changes test to check for lines in excess of 120 chars instead of 80
run-sharness script now correctly tracks exit codes and exits with error
2017-07-21 11:24:17 +02:00
Wyatt
633c97961c Fixing whitespace and minor Make issues 2017-05-05 10:02:07 -07:00
Wyatt
8286cd0ae2 Address 2nd round of comments 2017-05-05 10:00:17 -07:00
Wyatt
6f4c139cf9 Sharness Tests updated
I have attempted to address all of the comments on the original PR.
The sharness tests now make use of prereqs, see test-lib for details
and helper functions.
2017-05-05 09:59:23 -07:00
Wyatt
eac6c08a22 Sharness tests and library precondition setting fns updated 2017-05-05 09:59:22 -07:00
Wyatt
4a231b746f ctl basic cleanup 2017-05-05 09:59:22 -07:00
Wyatt
568b69b721 GPL compatability, fully automatic sharness build and clean 2017-05-05 09:59:22 -07:00
Wyatt
f547077700 Sharness Tests updated
I have attempted to address all of the comments on the original PR.
The sharness tests now make use of prereqs, see test-lib for details
and helper functions.
2017-05-05 09:09:48 -07:00
Wyatt
916b7e8849 Sharness tests and library precondition setting fns updated 2017-05-05 09:09:48 -07:00
Wyatt
148b08ffb8 ctl basic cleanup 2017-05-05 09:09:48 -07:00
Wyatt
1a966aee53 GPL compatability, fully automatic sharness build and clean 2017-05-05 09:09:47 -07:00