Go to file
Hector Sanjuan 196aa23f34 Fix #787: Connectivity fixes
Currently, unless doing Join() (--bootstrap), we do not connect to any peers on startup.

We however loaded up the peerstore file and Raft will automatically connect
older peers to figure out who is the leader etc. DHT bootstrap, after Raft
was working, did the rest.

For CRDTs we need to connect to people on a normal boot as otherwise, unless
bootstrapping, this does not happen, even if the peerstore contains known peers.

This introduces a number of changes:

* Move peerstore file management back inside the Cluster component, which was
already in charge of saving the peerstore file.
* We keep saving all "known addresses" but we load them with a non permanent
TTL, so that there will be clean up of peers we're not connected to for long.
* "Bootstrap" (connect) to a small number of peers during Cluster component creation.
* Bootstrap the DHT asap after this, so that other cluster components can
initialize with a working peer discovery mechanism.
* CRDT Trust() method will now:
  * Protect the trusted Peer ID in the conn manager
  * Give top priority in the PeerManager to that Peer (see below)
  * Mark addresses as permanent in the Peerstore

The PeerManager now attaches priorities to peers when importing them and is
able to order them according to that priority. The result is that peers with
high priority are saved first in the peerstore file. When we load the peerstore
file, the first entries in it are given the highest priority.

This means that during startup we will connect to "trusted peers" first
(because they have been tagged with priority in the previous run and saved at
the top of the list). Once connected to a small number of peers, we let the
DHT bootstrap process in the background do the rest and discover the network.

All this makes the peerstore file a "bootstrap" list for CRDTs and we will attempt
to connect to peers on that list until some of those connections succeed.
2019-05-27 14:27:23 +02:00
.github/ISSUE_TEMPLATE fix label in bug report 2019-04-29 18:01:12 +02:00
.gx gx publish 0.10.0 2019-03-07 18:03:51 +00:00
adder Feat: Split components into RPC Services 2019-05-04 21:36:10 +01:00
allocator Remove *Serial types. Use pointers for all types. 2019-02-27 17:04:35 +00:00
api Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00
cmd Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00
config service: multiple fixes around init and identities 2019-05-16 15:31:36 +02:00
consensus Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00
datastore Consensus: add new "crdt" consensus component 2019-04-17 19:14:26 +02:00
deptools Update gx and gx-go to latest stable 2018-10-31 17:12:12 +01:00
docker Docker: Run with daemon --upgrade by default. 2018-04-27 07:57:08 +02:00
informer Merge branch 'master' into feat/monitor-ring 2019-05-16 15:46:30 +02:00
ipfsconn/ipfshttp Merge branch 'master' into feat/monitor-ring 2019-05-16 15:46:30 +02:00
monitor monitor config: make threshold optional in the configuration 2019-05-16 12:52:40 +02:00
observations Merge branch 'master' into feat/monitor-ring 2019-05-16 15:46:30 +02:00
pintracker Merge branch 'master' into feat/monitor-ring 2019-05-16 15:46:30 +02:00
pstoremgr Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00
rpcutil policygen: Improve help text 2019-05-16 12:07:02 +02:00
sharness Disable some sharness tests adding with cid-version=1 2019-05-17 13:58:26 +02:00
state Consensus: add new "crdt" consensus component 2019-04-17 19:14:26 +02:00
test Test: remove removed endpoints from mock RPC 2019-05-09 22:52:02 +02:00
version Release 0.10.1 2019-04-10 12:04:43 +02:00
.codeclimate.yml codeclimate 2018-08-07 20:12:05 +02:00
.codecov.yml Tests: add failfast, bump to go1.12, adjust codecov 2019-05-17 13:54:13 +02:00
.dockerignore Issue #259: Address CR comments 2017-12-04 13:59:48 +01:00
.gitignore Add a docker-compose.yml example with 2 peers and auto-bootstrap. 2018-10-23 18:25:43 +02:00
.travis.yml Tests: multiple fixes 2019-05-20 23:45:04 +02:00
add_test.go Tests: multiple fixes 2019-05-20 23:45:04 +02:00
allocate.go Remove *Serial types. Use pointers for all types. 2019-02-27 17:04:35 +00:00
CHANGELOG.md Changelog for 0.10.1 2019-04-10 11:44:52 +02:00
cluster_config_test.go Feat: introduce a ConnectionManager for the libp2p host 2019-05-23 00:34:47 +02:00
cluster_config.go Feat: introduce a ConnectionManager for the libp2p host 2019-05-23 00:34:47 +02:00
cluster_test.go Tests: multiple fixes 2019-05-20 23:45:04 +02:00
cluster.go Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00
clusterhost.go Feat: introduce a ConnectionManager for the libp2p host 2019-05-23 00:34:47 +02:00
config_test.go Feat: introduce a ConnectionManager for the libp2p host 2019-05-23 00:34:47 +02:00
connect_graph.go Feat: Split components into RPC Services 2019-05-04 21:36:10 +01:00
CONTRIBUTING.md Docs: Move to website. 2018-04-27 09:05:11 +02:00
COPYRIGHT Dual-license the codebase. 2019-03-01 20:12:19 +00:00
docker-compose.yml Set CLUSTER_SECRET from shell 2018-10-24 21:20:53 +02:00
Dockerfile Tests: add failfast, bump to go1.12, adjust codecov 2019-05-17 13:54:13 +02:00
Dockerfile-bundle Docker: Run with daemon --upgrade by default. 2018-04-27 07:57:08 +02:00
Dockerfile-test Tests: add failfast, bump to go1.12, adjust codecov 2019-05-17 13:54:13 +02:00
go.mod Dependency update and cleanup to libp2p-0.0.30 2019-05-25 00:30:25 +02:00
go.sum Dependency update and cleanup to libp2p-0.0.30 2019-05-25 00:30:25 +02:00
ipfscluster_test.go Fix tests with new host lifecycle handling 2019-05-25 00:53:43 +02:00
ipfscluster.go ipfscluster.go: Add stops at the end of sentences 2019-05-13 23:22:08 +02:00
LICENSE-APACHE Dual-license the codebase. 2019-03-01 20:12:19 +00:00
LICENSE-MIT Dual-license the codebase. 2019-03-01 20:12:19 +00:00
logging.go Consensus: add new "crdt" consensus component 2019-04-17 19:14:26 +02:00
Makefile Tests: multiple fixes 2019-05-20 23:45:04 +02:00
package.json Consensus: add new "crdt" consensus component 2019-04-17 19:14:26 +02:00
peer_manager_test.go Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00
pnet_test.go Tests: multiple fixes 2019-05-20 23:45:04 +02:00
README.md docs: fix download link in readme 2019-03-18 09:42:43 +00:00
release.sh Do not do gx releases 2019-04-10 12:04:39 +02:00
rpc_api.go policygen: use format.Source() directly in code. 2019-05-15 10:46:03 +02:00
rpc_policy.go RPC Auth: make policygen.go generate a full rpc_policy.go 2019-05-13 23:22:08 +02:00
util.go Fix #787: Connectivity fixes 2019-05-27 14:27:23 +02:00

IPFS Cluster

Made by Main project IRC channel standard-readme compliant GoDoc Go Report Card Build Status codecov

Pinset orchestration for IPFS.

logo

IPFS Cluster is a stand-alone application and a CLI client that allocates, replicates, and tracks pins across a cluster of IPFS daemons.

It provides:

  • A cluster peer application: ipfs-cluster-service, to be run along with go-ipfs.
  • A client CLI application: ipfs-cluster-ctl, which allows easily interacting with the peer's HTTP API.

Are you using IPFS Cluster?

Please participate in the IPFS Cluster user registry.


Table of Contents

Documentation

Please visit https://cluster.ipfs.io/documentation/ to access user documentation, guides and any other resources, including detailed download and usage instructions.

News & Roadmap

We regularly post project updates to https://cluster.ipfs.io/news/ .

The most up-to-date Roadmap is available at https://cluster.ipfs.io/roadmap/ .

Install

Instructions for different installation methods (including from source) are available at https://cluster.ipfs.io/download .

Usage

Extensive usage information is provided at https://cluster.ipfs.io/documentation/ , including:

Contribute

PRs accepted. As part of the IPFS project, we have some contribution guidelines.

Small note: If editing the README, please conform to the standard-readme specification.

License

This library is dual-licensed under Apache 2.0 and MIT terms.

© 2019. Protocol Labs, Inc.