Documentation
¶
Index ¶
- type Api
- func (a *Api) AlerterAddHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) AlerterDeleteHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) AlerterGetHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) AlerterHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) ClusterHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) EventHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) EventWithTypeHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) HomeHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) MonitorAddHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) MonitorCheckHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) MonitorDeleteHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) MonitorDisableHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) MonitorHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) Run()
- func (a *Api) StateHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) StateWithTagsHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) StatusHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- func (a *Api) VersionHandler(rw http.ResponseWriter, r *http.Request) *rye.Response
- type JSONStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Api ¶
type Api struct { Config *config.Config MemberID string Identifier string MWHandler *rye.MWHandler DebugUI bool AccessTokens []string }
func (*Api) AlerterAddHandler ¶
Add/Update alerter config
func (*Api) AlerterDeleteHandler ¶
Delete alerter config
func (*Api) AlerterGetHandler ¶
func (*Api) AlerterHandler ¶
@Title Fetch Alerter Configuration @Description Fetch all (or specific) alerter configuration(s) from etcd @Accept json @Param check path string false "Specific check name" @Success 200 {array} fullAlerterConfig @Failure 500 {object} rye.JSONStatus @Router /alerter/{check} [get]
func (*Api) ClusterHandler ¶
@Title Fetch Cluster Stats @Description Fetches cluster state data (membership, current director, heartbeats) @Success 200 {object} dal.ClusterStats @Failure 500 {object} rye.JSONStatus @Router /cluster [get]
func (*Api) EventHandler ¶
@Title Fetch Events @Description Fetch event data (optionally filtered by one or more event types) @Accept json @Param type query string false "comma separated event types" @Success 200 {array} event.Event @Failure 500 {object} rye.JSONStatus @Router /event [get]
func (*Api) EventWithTypeHandler ¶
func (*Api) HomeHandler ¶
func (*Api) MonitorAddHandler ¶
Add/Update monitor config
func (*Api) MonitorCheckHandler ¶
func (*Api) MonitorDeleteHandler ¶
Delete monitor config
func (*Api) MonitorDisableHandler ¶
@Title Set Disabled State for Given Monitor @Description Enable or disable a specific monitor configuration (changes are immediate) @Accept json @Param check path string true "Specific check name" @Param disable query string false "Disable/enable a check" @Success 200 {array} rye.JSONStatus @Failure 500 {object} rye.JSONStatus @Router /monitor/{check} [get]
func (*Api) MonitorHandler ¶
@Title Fetch Monitor Configuration @Description Fetch all (or specific) monitor configuration(s) from etcd @Accept json @Param check path string false "Specific check name" @Success 200 {array} fullMonitorConfig @Failure 500 {object} rye.JSONStatus @Router /monitor/{check} [get]
func (*Api) StateHandler ¶
@Title Fetch Check State Data @Description Fetch check state data including latest check status, ownership, last check timestamp;
optionally filter the state data by checks that contain one or more tags.
@Accept json @Param tags query string false "One or more tags (comma separated)" @Success 200 {array} state.Message @Failure 500 {object} rye.JSONStatus @Router /state [get]