Version: v6.2.3+incompatible Latest Latest

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

Go to latest
Published: Mar 12, 2018 License: Apache-2.0 Imports: 9 Imported by: 0




This section is empty.


View Source
var ProviderRegistry = NewRegistry()

ProviderRegistry holds all known autodiscover providers, they must be added to it to enable them for use


func NewRegistry

func NewRegistry() *registry

NewRegistry creates and returns a new Registry


type Adapter

type Adapter interface {

	// CreateConfig generates a valid list of configs from the given event, the received event will have all keys defined by `StartFilter`
	CreateConfig(bus.Event) ([]*common.Config, error)

	// CheckConfig tests given config to check if it will work or not, returns errors in case it won't work
	CheckConfig(*common.Config) error

	// RunnerFactory provides runner creation by feeding valid configs

	// EventFilter returns the bus filter to retrieve runner start/stop triggering events
	EventFilter() []string

Adapter must be implemented by the beat in order to provide Autodiscover

type Autodiscover

type Autodiscover struct {
	// contains filtered or unexported fields

Autodiscover process, it takes a beat adapter and user config and runs autodiscover process, spawning new modules when any configured providers does a match

func NewAutodiscover

func NewAutodiscover(name string, adapter Adapter, config *Config) (*Autodiscover, error)

NewAutodiscover instantiates and returns a new Autodiscover manager

func (*Autodiscover) Start

func (a *Autodiscover) Start()

Start autodiscover process

func (*Autodiscover) Stop

func (a *Autodiscover) Stop()

Stop autodiscover process

type Config

type Config struct {
	Providers []*common.Config `config:"providers"`

Config settings for Autodiscover

type Provider

type Provider interface {

Provider for autodiscover

type ProviderBuilder

type ProviderBuilder func(bus.Bus, *common.Config) (Provider, error)

ProviderBuilder creates a new provider based on the given config and returns it

type ProviderConfig

type ProviderConfig struct {
	Type string `config:"type"`

ProviderConfig settings


Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL