plugins

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2024 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterPlugin

func RegisterPlugin(pluginName string, p Plugin)

Types

type Plugin

type Plugin interface {
	// ParseConfig is used to parse config
	ParseConfig(baseDir string, bs []byte) (any, error)
	// Scrape is used to scrape metrics, cfg need to be cast specific cfg
	Scrape(ctx context.Context, target string, cfg any, ss *types.Samples) error
}

func GetPlugin

func GetPlugin(pluginName string) (Plugin, bool)

Directories

Path Synopsis
exporter
Package exporter implements the collectors and metrics handlers.
Package exporter implements the collectors and metrics handlers.
internal/tu
Package tu has Test Util functions
Package tu has Test Util functions
dsn

Jump to

Keyboard shortcuts

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