health_check_http

package
v0.17.2 Latest Latest
Warning

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

Go to latest
Published: May 10, 2024 License: Apache-2.0 Imports: 8 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 {
	Protocol    string
	Method      string
	URL         string
	SuccessCode int
	Period      time.Duration
	Timeout     time.Duration
}

Config healthCheck所需配置

type HTTPCheck

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

HTTPCheck HTTP健康检查结构,实现了IHealthChecker接口

func NewHTTPCheck

func NewHTTPCheck(config Config) *HTTPCheck

NewHTTPCheck 创建HTTPCheck

func (*HTTPCheck) Check added in v0.12.5

func (h *HTTPCheck) Check(nodes discovery.INodes)

func (*HTTPCheck) Reset

func (h *HTTPCheck) Reset(conf interface{}) error

Reset 重置HTTPCheck的配置

func (*HTTPCheck) Stop

func (h *HTTPCheck) Stop()

Stop 停止HTTPCheck,中止定时检查

Jump to

Keyboard shortcuts

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