memory

package
v20.10.18+incompatible Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init()

Init registers the memory backend on demand.

Types

type Discovery

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

Discovery implements a discovery backend that keeps data in memory.

func (*Discovery) Initialize

func (s *Discovery) Initialize(_ string, heartbeat time.Duration, _ time.Duration, _ map[string]string) error

Initialize sets the heartbeat for the memory backend.

func (*Discovery) Register

func (s *Discovery) Register(addr string) error

Register adds a new address to the discovery.

func (*Discovery) Watch

func (s *Discovery) Watch(stopCh <-chan struct{}) (<-chan discovery.Entries, <-chan error)

Watch sends periodic discovery updates to a channel.

Jump to

Keyboard shortcuts

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