cluster

package
v0.0.0-...-edd4e79 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Node

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

func NewNode

func NewNode(option ...Option) *Node

func (*Node) Close

func (n *Node) Close() error

func (*Node) Name

func (n *Node) Name() string

func (*Node) Start

func (n *Node) Start(ctx context.Context) error

type Option

type Option func(*Node)

func WithClusterConfig

func WithClusterConfig(cfg config.Config) Option

func WithHostConfig

func WithHostConfig(cfg config.NodeHostConfig) Option

func WithInitMembers

func WithInitMembers(members map[uint64]string) Option

func WithJoin

func WithJoin(join bool) Option

func WithStateMachine

func WithStateMachine(state statemachine.IStateMachine) Option

Jump to

Keyboard shortcuts

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