healthcheck

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const NOTOK = "NOT OK"
View Source
const OK = "OK"

Variables

This section is empty.

Functions

func Do

func Do(ctx context.Context, cfg *config.Healthcheck) (map[string]any, int)

Types

type CachedResponses added in v0.1.3

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

func NewCachedResponses added in v0.1.3

func NewCachedResponses(ctx context.Context, cfg *config.Healthcheck) *CachedResponses

func (*CachedResponses) Response added in v0.1.3

func (ch *CachedResponses) Response() map[string]any

func (*CachedResponses) Status added in v0.1.3

func (ch *CachedResponses) Status() int

type ErrorResponse

type ErrorResponse struct {
	Error   string `json:"error,omitempty"`
	Message string `json:"message,omitempty"`
}

type Response

type Response struct {
	Name   string          `json:"name,omitempty"`
	URL    string          `json:"url,omitempty"`
	Errors []ErrorResponse `json:"errors,omitempty"`
	Status string          `json:"status,omitempty"`
}

Jump to

Keyboard shortcuts

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