Documentation ¶
Index ¶
- type Cluster
- func (c *Cluster) AddNode() (*Node, error)
- func (c *Cluster) AddNodes(n int) error
- func (c *Cluster) WaitForHealthy(ctx context.Context) error
- func (c *Cluster) WaitToDiscover(ctx context.Context, nodeAddr string) error
- func (c *Cluster) WaitToUpdate(ctx context.Context, nodeAddr string, key string, value string) error
- type Node
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cluster ¶
type Cluster struct {
// contains filtered or unexported fields
}
Cluster manages a local cluster used for testing and evaluation.
func NewCluster ¶
func NewCluster() *Cluster
func (*Cluster) WaitForHealthy ¶
WaitForHealthy waits for all nodes to discovery each other.
func (*Cluster) WaitToDiscover ¶
WaitToDiscover waits for all nodes to be notified about the node with the given addr joining the cluster.
type Node ¶
type Node struct {
Gossiper *scuttlebutt.Scuttlebutt
}
func (*Node) DiscoveredNode ¶
func (*Node) KnownPeers ¶
Click to show internal directories.
Click to hide internal directories.