consul

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Mar 27, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Worker added in v1.2.0

type Worker struct {
	SessionID string
	// contains filtered or unexported fields
}

func NewConsul added in v1.2.0

func NewConsul(consulURL, consulToken, key string, sessionTimeout time.Duration) (*Worker, error)

func (*Worker) AcquireLock added in v1.2.0

func (w *Worker) AcquireLock() error

func (*Worker) GetSnapshot added in v1.2.0

func (w *Worker) GetSnapshot() (string, error)

func (*Worker) ReleaseLock added in v1.2.0

func (w *Worker) ReleaseLock() error

func (*Worker) RenewSession added in v1.2.0

func (w *Worker) RenewSession(doneChan <-chan struct{}) error

Jump to

Keyboard shortcuts

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