cluster

package
v0.0.2-0...-6735cf7 Latest Latest
Warning

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

Go to latest
Published: May 2, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NodesChangeAddNode nodesChangeType = iota
	NodesChangeRemoveNode
)

Variables

View Source
var (
	NodeAddressNotFoundError error = errors.New("Node address not found")
)

Functions

This section is empty.

Types

type Conn

type Conn struct {
	// contains filtered or unexported fields
}

func NewConn

func NewConn(id uint64, address string, tlsCertFile string) (*Conn, error)

func (*Conn) AddNode

func (this *Conn) AddNode(id uint64, address string)

func (*Conn) Address

func (this *Conn) Address() string

func (*Conn) Close

func (this *Conn) Close()

func (*Conn) Dial

func (this *Conn) Dial(id uint64) (*grpc.ClientConn, error)

func (*Conn) DialAddress

func (this *Conn) DialAddress(address string) (*grpc.ClientConn, error)

func (*Conn) Id

func (this *Conn) Id() uint64

func (*Conn) NodeChangesNotifications

func (this *Conn) NodeChangesNotifications() <-chan *nodesChange

func (*Conn) NodeIds

func (this *Conn) NodeIds() []uint64

func (*Conn) Nodes

func (this *Conn) Nodes() map[uint64]string

func (*Conn) RemoveNode

func (this *Conn) RemoveNode(id uint64)

Jump to

Keyboard shortcuts

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