Hector Sanjuan
6c18c02106
Issue #10 : peers/add and peers/rm feature + tests
...
This commit adds PeerAdd() and PeerRemove() endpoints, CLI support,
tests. Peer management is a delicate issue because of how the consensus
works underneath and the places that need to track such peers.
When adding a peer the procedure is as follows:
* Try to open a connection to the new peer and abort if not reachable
* Broadcast a PeerManagerAddPeer operation which tells all cluster members
to add the new Peer. The Raft leader will add it to Raft's peerset and
the multiaddress will be saved in the ClusterPeers configuration key.
* If the above fails because some cluster node is not responding,
broadcast a PeerRemove() and try to undo any damage.
* If the broadcast succeeds, send our ClusterPeers to the new Peer along with
the local multiaddress we are using in the connection opened in the
first step (that is the multiaddress through which the other peer can reach us)
* The new peer updates its configuration with the new list and joins
the consensus
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-02-02 13:51:49 +01:00
Hector Sanjuan
77b8830419
Rename captain's log to CAPTAIN.LOG.md
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-27 15:33:45 +01:00
Hector Sanjuan
58a8a9f9ce
Update catchline
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-27 13:35:28 +01:00
Hector Sanjuan
43dea68edb
Update README, Captain log, fix logging.
...
Addresses some stuff in #19 .
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-27 13:30:15 +01:00
Hector Sanjuan
f6de900ddc
Merge pull request #36 from ipfs/9-ipfs-proxy-hijack
...
Fix #9 : Add customHandlers for pin/add pin/rm and pin/ls
2017-01-27 12:03:28 +01:00
Hector Sanjuan
592a20511e
Fix #9 : Add customHandlers for pin/add pin/rm and pin/ls
...
The proxy now mimics the IPFS daemon for these commands, except
the requests trigger cluster operations.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-27 11:58:49 +01:00
Hector Sanjuan
814b9dc0d5
Merge pull request #35 from ipfs/15-members-info
...
Fix #15 : Peers() provides lots of information now
2017-01-27 11:57:31 +01:00
Hector Sanjuan
4c1e0068f5
Fix #15 : Peers() provides lots of information now
...
I have renamed "members" to "peers".
Added IPFS daemon ID and addresses to the ID object and
have Peers() return the collection of ID() objects from the cluster.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-26 20:24:00 +01:00
Hector Sanjuan
204db61bc6
golint
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-26 13:04:27 +01:00
Hector Sanjuan
f7bf26237b
Update deps to latest raft and gorpc
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-26 13:01:35 +01:00
Hector Sanjuan
495ac27c57
Merge pull request #34 from ipfs/8-sync-all
...
Fixes #8 : Reworking PinTracker (sync/recover ops)
2017-01-26 12:52:46 +01:00
Hector Sanjuan
7f9cb0b269
Separate recover() from sync()
...
This includes adding a new API endpoint, CLI command.
I have also changed some api endpoints. I find:
POST /pins/<cid>/sync
POST /pins/<cid>/recover
GET /pins/<cid>
GET /pins
better. The problem is makes the pin list /pinlist but it general
its more consistent.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 20:17:19 +01:00
Hector Sanjuan
2566a0cca5
golint and misspellings
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 18:10:18 +01:00
Hector Sanjuan
58702d04bc
Issue 8: Make SyncAll efficient with a single PinLs call.
...
This has implied changes to the PinTracker API, to the IPFSConnector API and
a few renames on some PinTracker related constants.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 18:07:19 +01:00
Hector Sanjuan
d8d4a0094a
Import latest go-libp2p-gorpc
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 13:16:40 +01:00
Hector Sanjuan
3b8d643f86
gx publish 0.0.2
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 13:10:53 +01:00
Hector Sanjuan
cba87c28a2
Release 0.0.2
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 13:10:49 +01:00
Hector Sanjuan
9eb88f892d
Improve packages.json and add release script
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 13:09:36 +01:00
Hector Sanjuan
b388a45e92
Merge pull request #33 from ipfs/20-deps-mgmt
...
Dependency management: gx all deps + fetch gx from dist.ifps.io
Fixes #20 .
2017-01-25 12:56:09 +01:00
Hector Sanjuan
78aa03e2d8
A raft-boltdb import was permanently gx'ed
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 12:50:46 +01:00
Hector Sanjuan
9a47e6dd1f
Update go-libp2p-gorpc
...
Uses experimental version of multicodecs but should finally pin all deps
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 12:50:46 +01:00
Hector Sanjuan
cd307b08ad
Try to fix gx-go not rewriting correctly
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 12:50:05 +01:00
Hector Sanjuan
85092ede9a
Update libs. Make sure libp2p versions match
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 12:50:05 +01:00
Hector Sanjuan
8719d88e13
gx all dependencies
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 12:50:05 +01:00
Hector Sanjuan
154d4dab74
Issue #20 : Download a local installation of gx
...
This way we do not mess with the users stuff
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-25 12:48:16 +01:00
Hector Sanjuan
4cc3c1125b
Merge pull request #32 from ipfs/21-cli-tooling
...
Fixes #21 .
Rewrite the tools with urfave/cli.
Add Cluster.ID()
2017-01-25 12:44:03 +01:00
Hector Sanjuan
3f833a8c17
Use urfave/cli for ipfs-cluster-service too.
...
Added consistency to tools, plus it's worth the effot at this point.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 19:55:06 +01:00
Hector Sanjuan
8883ab3a74
Import cli in 1.19.1 tag
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 17:29:49 +01:00
Hector Sanjuan
1175f971fe
Update cli import with the right author
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 17:23:07 +01:00
Hector Sanjuan
81db084249
Make sure the commit string gets set. Fix PublicKey. Output JSON in cluster-ctl
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 16:56:14 +01:00
Hector Sanjuan
f19c4b5567
fix lowercase commit symbol
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 16:33:34 +01:00
Hector Sanjuan
dddd53fe5f
Fix -X parameter
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 16:29:37 +01:00
Hector Sanjuan
d5fc795ee5
Re-add version method to cluster-ctl
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 16:26:42 +01:00
Hector Sanjuan
9111c6282c
Issue-21: Add cluster ID() method
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 16:26:42 +01:00
Hector Sanjuan
50de95d464
Issue-21: Use https://github.com/urfave/cli for cluster-ctl
...
Rewrote the app with better command and help support.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 16:25:53 +01:00
Hector Sanjuan
af177bfde6
Address formatting, mispellings, lint errors from goreportcard
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 12:39:08 +01:00
Hector Sanjuan
9af863e3e0
Merge pull request #29 from ipfs/25-leader-comm
...
Fix #25 : Only the consensus layer should deal with leaders
2017-01-24 01:13:42 +01:00
Hector Sanjuan
e9698490b0
Improve handling of errors in GlobalPinInfo
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 01:09:27 +01:00
Hector Sanjuan
b3039b85d5
global status and global sync should not error when a node is down
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 00:54:26 +01:00
Hector Sanjuan
9efa2d063f
Merge pull request #31 from ipfs/22-configs
...
Fix #22 : Address feedback regarding configuration
2017-01-24 00:51:40 +01:00
Hector Sanjuan
24c8253c9e
Fix config example
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-24 00:46:21 +01:00
Hector Sanjuan
afa8a5c33f
Improve startup messages and information
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 23:58:04 +01:00
Hector Sanjuan
8293965b88
Merge pull request #30 from mateon1/fix/proofread-and-whitespace
...
Fix typo and remove trailing whitespace.
2017-01-23 22:54:53 +01:00
Hector Sanjuan
e932b2f3f6
Fix tests with raftCfg config section and do not panic if its not there
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 21:07:16 +01:00
Hector Sanjuan
d987073201
Improve docs for the new configuration formats
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 20:56:35 +01:00
Hector Sanjuan
7954556848
Improve error messages with fishy configurations
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 20:39:09 +01:00
Hector Sanjuan
84a7fa663d
Workaround tests failing randomly
...
Tracked down reason to: https://github.com/libp2p/go-libp2p-swarm/issues/15
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 20:29:05 +01:00
Hector Sanjuan
74c494eb1e
Fix configuration generation.
...
Add a custom RaftConfig section which is limited to whatever
values we want to leave to the user.
Make sure the consensus data is, by default, next to the service.json file.
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 19:06:00 +01:00
Hector Sanjuan
d1731ebd28
Use multiaddresses in the configuration and rename JSON entries for clarity
...
License: MIT
Signed-off-by: Hector Sanjuan <hector@protocol.ai>
2017-01-23 18:38:59 +01:00
mateon1
51f87407c6
Fix typo and remove trailing whitespace.
...
License: MIT
Signed-off-by: Mateusz Naściszewski <matin1111@wp.pl>
2017-01-23 14:21:26 +01:00