plugin

package
v0.5.2 Latest Latest
Warning

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

Go to latest
Published: May 22, 2024 License: Apache-2.0 Imports: 6 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetRegisteredAdvisorPlugins added in v0.2.0

func GetRegisteredAdvisorPlugins() map[string]AdvisorPluginInitFunc

func RegisterAdvisorPlugin added in v0.2.0

func RegisterAdvisorPlugin(plugin string, f AdvisorPluginInitFunc)

Types

type AdvisorPluginInitFunc added in v0.2.0

type AdvisorPluginInitFunc func(pluginName string, conf *config.Configuration, extraConf interface{},
	emitterPool metricspool.MetricsEmitterPool, metaServer *metaserver.MetaServer,
	metaCache metacache.MetaCache) (SysAdvisorPlugin, error)

AdvisorPluginInitFunc is used to initialize a particular inter SysAdvisor plugin.

type DummySysAdvisorPlugin

type DummySysAdvisorPlugin struct{}

func (DummySysAdvisorPlugin) Init

func (d DummySysAdvisorPlugin) Init() error

func (DummySysAdvisorPlugin) Name

func (d DummySysAdvisorPlugin) Name() string

func (DummySysAdvisorPlugin) Run

type SysAdvisorPlugin

type SysAdvisorPlugin interface {
	Name() string
	Init() error
	Run(ctx context.Context)
}

SysAdvisorPlugin performs resource control computation based on agent resources.

Jump to

Keyboard shortcuts

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