Documentation
¶
Overview ¶
Package mockrouting provides a virtual routing server. To use it, create a virtual routing server and use the Client() method to get a routing client (Routing). The server quacks like a DHT but is really a local in-memory hash table.
Index ¶
- type Clientdeprecated
- type DelayConfigdeprecated
- type MockValidatordeprecated
- type Serverdeprecated
- func NewServer() Serverdeprecated
- func NewServerWithDelay(conf DelayConfig) Serverdeprecated
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DelayConfig
deprecated
type DelayConfig struct {
// ValueVisibility is the time it takes for a value to be visible in the network
// FIXME there _must_ be a better term for this
ValueVisibility delay.D
// Query is the time it takes to receive a response from a routing query
Query delay.D
}
DelayConfig can be used to configured the fake delays of a mock server. Use with NewServerWithDelay().
Deprecated: use github.com/ipfs/boxo/routing/mock.DelayConfig
type MockValidator
deprecated
type MockValidator struct{}
MockValidator is a record validator that always returns success.
Deprecated: use github.com/ipfs/boxo/routing/mock.MockValidator
type Server
deprecated
type Server interface {
Client(p tnet.Identity) Client
ClientWithDatastore(context.Context, tnet.Identity, ds.Datastore) Client
}
Server provides mockrouting Clients
Deprecated: use github.com/ipfs/boxo/routing/mock.Server
func NewServerWithDelay
deprecated
func NewServerWithDelay(conf DelayConfig) Server
NewServerWithDelay returns a mockrouting Server with a delay!
Deprecated: use github.com/ipfs/boxo/routing/mock.NewServerWithDelay