Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bucket ¶
type Bucket interface { Routing() []pb.Node Cache() []pb.Node // TODO: should this be a NodeID? Midpoint() string Nodes() []*pb.Node }
Bucket is a set of methods to act on kademlia k buckets
type DHT ¶
type DHT interface { FindNear(ctx context.Context, start storj.NodeID, limit int) ([]*pb.Node, error) Bootstrap(ctx context.Context) error Ping(ctx context.Context, node pb.Node) (pb.Node, error) FindNode(ctx context.Context, ID storj.NodeID) (pb.Node, error) Seen() []*pb.Node }
DHT is the interface for the DHT in the Storj network
type RoutingTable ¶
type RoutingTable interface { // local params Local() overlay.NodeDossier K() int CacheSize() int GetBucketIds(context.Context) (storage.Keys, error) FindNear(ctx context.Context, id storj.NodeID, limit int) ([]*pb.Node, error) ConnectionSuccess(ctx context.Context, node *pb.Node) error ConnectionFailed(ctx context.Context, node *pb.Node) error // these are for refreshing SetBucketTimestamp(ctx context.Context, id []byte, now time.Time) error GetBucketTimestamp(ctx context.Context, id []byte) (time.Time, error) Close() error }
RoutingTable contains information on nodes we have locally
Click to show internal directories.
Click to hide internal directories.