plugin

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Nov 24, 2023 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	PluginID = plugins.PluginID{
		Name:       pluginName,
		PluginType: sdk.PluginTypeAPM,
	}

	PluginConfig = &plugins.InternalPluginConfig{
		Factory: func(l hclog.Logger) interface{} { return NewMetricsPlugin(l) },
	}
)

Functions

func NewMetricsPlugin

func NewMetricsPlugin(log hclog.Logger) apm.APM

NewMetricsPlugin returns the Periods implementation of the strategy.Strategy interface.

Types

type APMPlugin

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

APMPlugin is the implementation of the apm.APM interface.

func (*APMPlugin) PluginInfo

func (a *APMPlugin) PluginInfo() (*base.PluginInfo, error)

PluginInfo satisfies the PluginInfo function on the base.Base interface.

func (*APMPlugin) Query

Query satisfies the Query function on the apm.APM interface.

func (*APMPlugin) QueryMultiple

func (a *APMPlugin) QueryMultiple(q string, r sdk.TimeRange) ([]sdk.TimestampedMetrics, error)

QueryMultiple satisfies the QueryMultiple function on the apm.APM interface

func (*APMPlugin) SetConfig

func (a *APMPlugin) SetConfig(config map[string]string) error

SetConfig satisfies the SetConfig function on the base.Base interface.

Jump to

Keyboard shortcuts

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