Documentation
¶
Index ¶
- func CheckProbeConfig(probes []modules.Prober) error
- func CheckProbeData(pd *modules.ProbeData) error
- func HandleConfig(config []byte) http.HandlerFunc
- func HandleHomePage(w http.ResponseWriter, r *http.Request)
- func HandleStatus(ps *ProbesStatus) http.HandlerFunc
- type ProbeStatus
- type ProbesStatus
- func (ps *ProbesStatus) ConvertToInt(i *float64) int
- func (ps *ProbesStatus) FormattedHttpBody(body *[]byte) string
- func (ps *ProbesStatus) FormattedHttpHeaders(h http.Header) template.HTML
- func (ps *ProbesStatus) FormattedTime(t *int64) time.Time
- func (ps *ProbesStatus) ReadProbeStatus(pn string) *ProbeStatus
- func (ps *ProbesStatus) WriteProbeErrorStatus(pn string, st int64, et int64)
- func (ps *ProbesStatus) WriteProbeStatus(pn string, pd *modules.ProbeData, st int64, et int64)
- func (ps *ProbesStatus) WriteProbeTimeoutStatus(pn string, st int64, et int64)
- type TemplateParams
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckProbeConfig ¶ added in v0.5.0
CheckProbeConfig function does sanity checks on the probe definition.
func CheckProbeData ¶ added in v0.5.0
CheckProbedata function verifies the correctness of the probe response.
func HandleConfig ¶ added in v0.5.0
func HandleConfig(config []byte) http.HandlerFunc
TODO: Return pure json instead of html.
func HandleHomePage ¶ added in v0.5.0
func HandleHomePage(w http.ResponseWriter, r *http.Request)
func HandleStatus ¶ added in v0.5.0
func HandleStatus(ps *ProbesStatus) http.HandlerFunc
Types ¶
type ProbeStatus ¶
type ProbesStatus ¶
type ProbesStatus struct {
Tmpl TemplateParams
Probes []string
ProbeStatusMap map[string]*ProbeStatus
// contains filtered or unexported fields
}
func NewProbesStatus ¶
func NewProbesStatus(p []string) *ProbesStatus
func (*ProbesStatus) ConvertToInt ¶
func (ps *ProbesStatus) ConvertToInt(i *float64) int
func (*ProbesStatus) FormattedHttpBody ¶
func (ps *ProbesStatus) FormattedHttpBody(body *[]byte) string
func (*ProbesStatus) FormattedHttpHeaders ¶
func (ps *ProbesStatus) FormattedHttpHeaders(h http.Header) template.HTML
func (*ProbesStatus) FormattedTime ¶
func (ps *ProbesStatus) FormattedTime(t *int64) time.Time
func (*ProbesStatus) ReadProbeStatus ¶
func (ps *ProbesStatus) ReadProbeStatus(pn string) *ProbeStatus
func (*ProbesStatus) WriteProbeErrorStatus ¶
func (ps *ProbesStatus) WriteProbeErrorStatus(pn string, st int64, et int64)
func (*ProbesStatus) WriteProbeStatus ¶
func (*ProbesStatus) WriteProbeTimeoutStatus ¶
func (ps *ProbesStatus) WriteProbeTimeoutStatus(pn string, st int64, et int64)
type TemplateParams ¶
Click to show internal directories.
Click to hide internal directories.