rainbond: github.com/goodrain/rainbond/util/prober/types/v1 Index | Files

package v1

import "github.com/goodrain/rainbond/util/prober/types/v1"

Index

Package Files

types.go

Constants

const (
    // StatHealthy -
    StatHealthy string = "healthy"
    // StatUnhealthy -
    StatUnhealthy string = "unhealthy"
    // StatDeath -
    StatDeath string = "death"
)

type Health Uses

type Health struct {
    Name         string `json:"name"`
    Model        string `json:"model"`
    IP           string `json:"ip"`
    Port         int    `json:"port"`
    Address      string `json:"address"`
    TimeInterval int    `json:"time_interval"`
    MaxErrorsNum int    `json:"max_errors_num"`
}

Health ServiceHealth

func (*Health) Equal Uses

func (l *Health) Equal(r *Health) bool

Equal check if the left health(l) is equal to the right health(r)

type HealthStatus Uses

type HealthStatus struct {
    Name           string        `json:"name"`
    Status         string        `json:"status"`
    ErrorNumber    int           `json:"error_number"`
    ErrorDuration  time.Duration `json:"error_duration"`
    StartErrorTime time.Time     `json:"start_error_time"`
    Info           string        `json:"info"`
    LastStatus     string        `json:"last_status"`
    StatusChange   bool          `json:"status_change"`
}

HealthStatus health status

type Service Uses

type Service struct {
    Sid           string  `json:"service_id"`
    Name          string  `json:"name"`
    ServiceHealth *Health `json:"health"`
    Disable       bool    `json:"disable"`
}

Service Service

func (*Service) Equal Uses

func (l *Service) Equal(r *Service) bool

Equal check if the left service(l) is equal to the right service(r)

Package v1 imports 1 packages (graph) and is imported by 3 packages. Updated 2019-05-15. Refresh now. Tools for package owners.