Commit caeecd0f authored by Juan Batiz-Benet's avatar Juan Batiz-Benet Committed by Brian Tiger Chow

starting to integrate new net

parent 9f04d5e8
......@@ -7,7 +7,7 @@ import (
"sync"
"time"
swarm "github.com/jbenet/go-ipfs/net/swarm"
inet "github.com/jbenet/go-ipfs/net"
peer "github.com/jbenet/go-ipfs/peer"
kb "github.com/jbenet/go-ipfs/routing/kbucket"
u "github.com/jbenet/go-ipfs/util"
......@@ -28,8 +28,7 @@ type IpfsDHT struct {
// NOTE: (currently, only a single table is used)
routingTables []*kb.RoutingTable
network swarm.Network
netChan *swarm.Chan
network inet.Network
// Local peer (yourself)
self *peer.Peer
......@@ -48,9 +47,6 @@ type IpfsDHT struct {
//lock to make diagnostics work better
diaglock sync.Mutex
// listener is a server to register to listen for responses to messages
listener *swarm.MessageListener
}
// NewDHT creates a new DHT object with the given peer as the 'local' host
......
......@@ -6,7 +6,7 @@ import (
ds "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/datastore.go"
ma "github.com/jbenet/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-multiaddr"
ci "github.com/jbenet/go-ipfs/crypto"
identify "github.com/jbenet/go-ipfs/identify"
spipe "github.com/jbenet/go-ipfs/crypto/spipe"
swarm "github.com/jbenet/go-ipfs/net/swarm"
peer "github.com/jbenet/go-ipfs/peer"
u "github.com/jbenet/go-ipfs/util"
......@@ -36,7 +36,7 @@ func setupDHTS(n int, t *testing.T) ([]*ma.Multiaddr, []*peer.Peer, []*IpfsDHT)
}
p.PubKey = pk
p.PrivKey = sk
id, err := identify.IDFromPubKey(pk)
id, err := spipe.IDFromPubKey(pk)
if err != nil {
panic(err)
}
......@@ -68,7 +68,7 @@ func makePeer(addr *ma.Multiaddr) *peer.Peer {
}
p.PrivKey = sk
p.PubKey = pk
id, err := identify.IDFromPubKey(pk)
id, err := spipe.IDFromPubKey(pk)
if err != nil {
panic(err)
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment