mirror of
https://github.com/libp2p/go-libp2p-peerstore.git
synced 2025-01-15 02:40:07 +08:00
extract from 0.4.0
This commit is contained in:
parent
a754102d02
commit
5e7bc7b555
@ -2,7 +2,7 @@
|
||||
package addr
|
||||
|
||||
import (
|
||||
ma "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
|
||||
ma "github.com/jbenet/go-multiaddr"
|
||||
)
|
||||
|
||||
// AddrSource is a source of addresses. It allows clients to retrieve
|
||||
|
@ -4,7 +4,7 @@ import (
|
||||
"fmt"
|
||||
"testing"
|
||||
|
||||
ma "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
|
||||
ma "github.com/jbenet/go-multiaddr"
|
||||
)
|
||||
|
||||
func newAddrOrFatal(t *testing.T, s string) ma.Multiaddr {
|
||||
|
@ -4,7 +4,7 @@ import (
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
ma "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
|
||||
ma "github.com/jbenet/go-multiaddr"
|
||||
)
|
||||
|
||||
const (
|
||||
|
@ -4,7 +4,7 @@ import (
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
ma "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
|
||||
ma "github.com/jbenet/go-multiaddr"
|
||||
)
|
||||
|
||||
func IDS(t *testing.T, ids string) ID {
|
||||
|
@ -6,8 +6,8 @@ import (
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
testutil "github.com/ipfs/go-ipfs/util/testutil"
|
||||
peer "github.com/ipfs/go-libp2p/p2p/peer"
|
||||
testutil "util/testutil"
|
||||
)
|
||||
|
||||
func TestLatencyEWMAFun(t *testing.T) {
|
||||
|
10
peer.go
10
peer.go
@ -7,13 +7,13 @@ import (
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
b58 "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-base58"
|
||||
ma "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
|
||||
mh "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multihash"
|
||||
b58 "github.com/jbenet/go-base58"
|
||||
ma "github.com/jbenet/go-multiaddr"
|
||||
mh "github.com/jbenet/go-multihash"
|
||||
|
||||
u "github.com/ipfs/go-ipfs/util"
|
||||
logging "github.com/ipfs/go-ipfs/vendor/go-log-v1.0.0"
|
||||
logging "QmWRypnfEwrgH4k93KEHN5hng7VjKYkWmzDYRuTZeh2Mgh/go-log"
|
||||
ic "github.com/ipfs/go-libp2p/p2p/crypto"
|
||||
u "util"
|
||||
)
|
||||
|
||||
var log = logging.Logger("peer")
|
||||
|
@ -6,12 +6,12 @@ import (
|
||||
"strings"
|
||||
"testing"
|
||||
|
||||
u "github.com/ipfs/go-ipfs/util"
|
||||
tu "github.com/ipfs/go-ipfs/util/testutil"
|
||||
ic "github.com/ipfs/go-libp2p/p2p/crypto"
|
||||
. "github.com/ipfs/go-libp2p/p2p/peer"
|
||||
u "util"
|
||||
tu "util/testutil"
|
||||
|
||||
b58 "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-base58"
|
||||
b58 "github.com/jbenet/go-base58"
|
||||
)
|
||||
|
||||
var gen1 keyset // generated
|
||||
|
@ -7,9 +7,9 @@ import (
|
||||
|
||||
ic "github.com/ipfs/go-libp2p/p2p/crypto"
|
||||
|
||||
ds "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-datastore"
|
||||
dssync "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-datastore/sync"
|
||||
ma "github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
|
||||
ds "github.com/jbenet/go-datastore"
|
||||
dssync "github.com/jbenet/go-datastore/sync"
|
||||
ma "github.com/jbenet/go-multiaddr"
|
||||
)
|
||||
|
||||
const (
|
||||
|
@ -5,9 +5,9 @@ import (
|
||||
"math/big"
|
||||
"sync"
|
||||
|
||||
key "github.com/ipfs/go-ipfs/blocks/key"
|
||||
ks "github.com/ipfs/go-ipfs/routing/keyspace"
|
||||
ks "Qma4vHVBYKDiKS5VpvtLNJHHDbL7S6VRsvxxmBnBFfKP3k/go-keyspace"
|
||||
peer "github.com/ipfs/go-libp2p/p2p/peer"
|
||||
key "github.com/whyrusleeping/go-key"
|
||||
)
|
||||
|
||||
// peerMetric tracks a peer and its distance to something else.
|
||||
|
@ -6,11 +6,11 @@ import (
|
||||
"testing"
|
||||
"time"
|
||||
|
||||
key "github.com/ipfs/go-ipfs/blocks/key"
|
||||
u "github.com/ipfs/go-ipfs/util"
|
||||
peer "github.com/ipfs/go-libp2p/p2p/peer"
|
||||
key "github.com/whyrusleeping/go-key"
|
||||
u "util"
|
||||
|
||||
context "github.com/ipfs/go-ipfs/Godeps/_workspace/src/golang.org/x/net/context"
|
||||
context "golang.org/x/net/context"
|
||||
)
|
||||
|
||||
func TestQueue(t *testing.T) {
|
||||
|
@ -1,9 +1,9 @@
|
||||
package queue
|
||||
|
||||
import (
|
||||
context "github.com/ipfs/go-ipfs/Godeps/_workspace/src/golang.org/x/net/context"
|
||||
logging "github.com/ipfs/go-ipfs/vendor/go-log-v1.0.0"
|
||||
context "golang.org/x/net/context"
|
||||
peer "github.com/ipfs/go-libp2p/p2p/peer"
|
||||
logging "QmWRypnfEwrgH4k93KEHN5hng7VjKYkWmzDYRuTZeh2Mgh/go-log"
|
||||
)
|
||||
|
||||
var log = logging.Logger("peerqueue")
|
||||
|
Loading…
Reference in New Issue
Block a user