config

package
v1.20.11 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// DynamicPluginType dynamic lib
	DynamicPluginType PluginType = "dynamic-plugin"
	// ExecutablePluginType executable file
	ExecutablePluginType PluginType = "executable-plugin"
	// DefaultTimeout default timeout for plugin invocation
	DefaultTimeout int = 5
)

Variables

This section is empty.

Functions

This section is empty.

Types

type PluginConfig

type PluginConfig struct {
	Version      string                   `json:"version"`
	Name         string                   `json:"name"`
	Type         PluginType               `json:"type"`
	DefaultAtrrs []*typesplugin.Attribute `json:"defaultAttrs"`
	Timeout      int                      `json:"timeout"`
}

PluginConfig configuration for loading plugin

func NewConfig

func NewConfig(path string) (*PluginConfig, error)

NewConfig loading plugin config with specified file

type PluginType

type PluginType string

PluginType type of plugin, dynamic lib/executable-file

Jump to

Keyboard shortcuts

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