Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BasicResponse ¶
type BasicResponse struct {
Messages []string `json:"messages"`
}
BasicResponse a type for HTTP responses
type BulkPayload ¶
type BulkPayload struct { DNSChecks []healthcheck.DNSHealthcheckConfiguration `json:"dns-checks"` CommandChecks []healthcheck.CommandHealthcheckConfiguration `json:"command-checks"` TCPChecks []healthcheck.TCPHealthcheckConfiguration `json:"tcp-checks"` HTTPChecks []healthcheck.HTTPHealthcheckConfiguration `json:"http-checks"` TLSChecks []healthcheck.TLSHealthcheckConfiguration `json:"tls-checks"` }
BulkPayload the paylaod for bulk requests fo healthchecks
func (*BulkPayload) Validate ¶
func (p *BulkPayload) Validate() error
Validate validates the payload for bulk requests
type Component ¶
type Component struct { MemoryStore *memorystore.MemoryStore Config *Configuration Logger *zap.Logger Server *echo.Echo Prometheus *prometheus.Prometheus // contains filtered or unexported fields }
Component the http server component
func New ¶
func New(logger *zap.Logger, memstore *memorystore.MemoryStore, promComponent *prometheus.Prometheus, config *Configuration, healthcheck *healthcheck.Component) (*Component, error)
New creates a new HTTP component
type Configuration ¶
type Configuration struct { Host string Port uint32 DisableHealthcheckAPI bool `yaml:"disable-healthcheck-api,omitempty"` DisableResultAPI bool `yaml:"disable-result-api,omitempty"` Key string Cert string BasicAuth BasicAuth `yaml:"basic-auth"` AllowedCN []string `yaml:"allowed-cn"` Cacert string }
Configuration the HTTP server configuration
func (*Configuration) UnmarshalYAML ¶
func (c *Configuration) UnmarshalYAML(unmarshal func(interface{}) error) error
UnmarshalYAML parses the configuration of the http component from YAML.
Click to show internal directories.
Click to hide internal directories.