hystrix

package
v1.0.0-dev.144 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PluginsRoot = root + ".plugins"
)

Variables

This section is empty.

Functions

func CommandConfigAdd

func CommandConfigAdd(cmd string)

func CommandConfigsAdd

func CommandConfigsAdd(cmds []string)

func ConfigureCommand

func ConfigureCommand(cmd string) error

func ConfigureCommandWithOptions

func ConfigureCommandWithOptions(cmd string, options *Options) error

func ConfigureCommands

func ConfigureCommands(cmds []string) error

Types

type Options

type Options struct {
	Enabled                bool
	Timeout                int
	RequestVolumeThreshold int
	ErrorPercentThreshold  int
	MaxConcurrentRequests  int
	SleepWindow            int
}

func NewOptionsFromCommand

func NewOptionsFromCommand(cmd string) (*Options, error)

NewOptionsFromCommand unmarshals options based a given key path.

type Plugin

type Plugin func(context.Context) error

Plugin defines a function to process plugin.

Directories

Path Synopsis
plugins

Jump to

Keyboard shortcuts

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