zk

package
v0.0.0-...-22e582f Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2019 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Coordinator

type Coordinator struct {
	sync.Mutex
	// contains filtered or unexported fields
}

Coordinator implements leader election systems backed by ZooKeeper.

func New

func New(c *conf.CoordinatorZK) (*Coordinator, error)

New creates new ZooKeeper-backed coordinator.

func (*Coordinator) WaitUntilLeader

func (coord *Coordinator) WaitUntilLeader() context.Context

WaitUntilLeader blocks until this coordinator instance becomes a leader.

Jump to

Keyboard shortcuts

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