checker

package
v2.0.0-beta9 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// PluginName declares public plugin name.
	PluginName = "status"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Checker

type Checker interface {
	Status() Status
}

Checker interface used to get latest status from plugin

type Config

type Config struct {
	Address string
}

type Plugin

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

func (*Plugin) CollectTarget

func (c *Plugin) CollectTarget(name endure.Named, r Checker) error

CollectTarget collecting services which can provide Status.

func (*Plugin) Collects

func (c *Plugin) Collects() []interface{}

Collects declares services to be collected.

func (*Plugin) Init

func (c *Plugin) Init(log logger.Logger, cfg config.Configurer) error

func (*Plugin) Name

func (c *Plugin) Name() string

Name of the service.

func (*Plugin) RPC

func (c *Plugin) RPC() interface{}

RPCService returns associated rpc service.

func (*Plugin) Serve

func (c *Plugin) Serve() chan error

func (*Plugin) Status

func (c *Plugin) Status(name string) (Status, error)

Reset named service.

func (*Plugin) Stop

func (c *Plugin) Stop() error

type Plugins

type Plugins struct {
	Plugins []string `query:"plugin"`
}

type Status

type Status struct {
	Code int
}

Status consists of status code from the service

Jump to

Keyboard shortcuts

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