routing

package
v0.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 22, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PeerRouting

type PeerRouting interface {
	FindPeer(ctx context.Context, service string, targetPeerId peer.ID, timeout time.Duration) (peer.ID, error)
}

PeerRouting provides a way to query the net address of the peer in network.

type ProtocolRouting

type ProtocolRouting interface {
	FindPeerSupportProtocolsAsync(context.Context, int, ...protocol.ID) <-chan ma.Multiaddr
}

ProtocolRouting provides a way to query the net addresses of the peers who support protocols given.

type Routing

type Routing interface {
	PeerRouting
	ProtocolRouting
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL