rcm

package
v1.9.2 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2021 License: Apache-2.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

Types

type InstanceAssignment

type InstanceAssignment struct {
	Instance string
	TotalLag int64
	TaskLags []TaskLag
}

type NacosConfManager

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

func (*NacosConfManager) Deregister

func (ncm *NacosConfManager) Deregister(ip string, port int) (err error)

func (*NacosConfManager) GetConfig

func (ncm *NacosConfManager) GetConfig() (conf *config.Config, err error)

func (*NacosConfManager) Init

func (ncm *NacosConfManager) Init(properties map[string]interface{}) (err error)

func (*NacosConfManager) PublishConfig

func (ncm *NacosConfManager) PublishConfig(conf *config.Config) (err error)

func (*NacosConfManager) Register

func (ncm *NacosConfManager) Register(ip string, port int) (err error)

func (*NacosConfManager) Run

func (ncm *NacosConfManager) Run()

func (*NacosConfManager) Stop

func (ncm *NacosConfManager) Stop()

type RemoteConfManager

type RemoteConfManager interface {
	Init(properties map[string]interface{}) error
	GetConfig() (conf *config.Config, err error)
	// PublishConfig publishs the config.
	PublishConfig(conf *config.Config) (err error)
	Register(ip string, port int) (err error)
	Deregister(ip string, port int) (err error)

	// Assignment loop
	Run()
	Stop()
}

RemoteConfManager can be implemented by many backends: Nacos, Consul, etcd, ZooKeeper...

type TaskLag

type TaskLag struct {
	Task string
	Lag  int64
}

Jump to

Keyboard shortcuts

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