tcp

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2023 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause, + 3 more Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
}

Config 健康探测的配置

func (*Config) SetDefault

func (r *Config) SetDefault()

SetDefault 设置默认值

func (*Config) Verify

func (r *Config) Verify() error

Verify 检验健康探测配置

type Detector

type Detector struct {
	*plugin.PluginBase

	SendPackageBytes    []byte
	ReceivePackageBytes [][]byte
	// contains filtered or unexported fields
}

Detector TCP协议的实例健康探测器

func (*Detector) Destroy

func (g *Detector) Destroy() error

Destroy 销毁插件,可用于释放资源

func (*Detector) DetectInstance

func (g *Detector) DetectInstance(ins model.Instance) (result healthcheck.DetectResult, err error)

DetectInstance 探测服务实例健康

func (*Detector) Init

func (g *Detector) Init(ctx *plugin.InitContext) (err error)

Init 初始化插件

func (*Detector) IsEnable

func (g *Detector) IsEnable(cfg config.Configuration) bool

IsEnable enable

func (*Detector) Name

func (g *Detector) Name() string

Name 插件名,一个类型下插件名唯一

func (*Detector) Type

func (g *Detector) Type() common.Type

Type 插件类型

Jump to

Keyboard shortcuts

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