Documentation ¶
Index ¶
- func NewHandlerInstance(handlerConfig *models.HandlerConfig) models.HandlerInterface
- type Handler
- func (h *Handler) AdapterPingHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) AuthMiddleware(next http.Handler) http.Handler
- func (h *Handler) CollectStaticMetrics(config *models.SubmitMetricsConfig) error
- func (h *Handler) EventStreamHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) FetchResultsHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GetAllAdaptersHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GetContextsFromK8SConfig(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GrafanaBoardImportForPrometheusHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GrafanaBoardsHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GrafanaConfigHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GrafanaQueryHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) GrafanaQueryRangeHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) K8SConfigHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) LoadTestHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) LoginHandler(w http.ResponseWriter, r *http.Request)
- func (h *Handler) LogoutHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) MeshAdapterConfigHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) MeshOpsHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) PrometheusConfigHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) PrometheusQueryHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) PrometheusQueryRangeHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) PrometheusStaticBoardHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) SaveSelectedGrafanaBoardsHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) SaveSelectedPrometheusBoardsHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) SessionSyncHandler(w http.ResponseWriter, req *http.Request)
- func (h *Handler) UserHandler(w http.ResponseWriter, req *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewHandlerInstance ¶ added in v0.0.4
func NewHandlerInstance( handlerConfig *models.HandlerConfig, ) models.HandlerInterface
NewHandlerInstance returns a Handler instance
Types ¶
type Handler ¶ added in v0.0.4
type Handler struct {
// contains filtered or unexported fields
}
Handler type is the bucket for configs and http handlers
func (*Handler) AdapterPingHandler ¶ added in v0.0.6
func (h *Handler) AdapterPingHandler(w http.ResponseWriter, req *http.Request)
AdapterPingHandler is used to ping a given adapter
func (*Handler) AuthMiddleware ¶ added in v0.0.4
AuthMiddleware is a middleware to validate if a user is authenticated
func (*Handler) CollectStaticMetrics ¶ added in v0.0.6
func (h *Handler) CollectStaticMetrics(config *models.SubmitMetricsConfig) error
CollectStaticMetrics is used for collecting static metrics from prometheus and submitting it to SaaS
func (*Handler) EventStreamHandler ¶ added in v0.0.6
func (h *Handler) EventStreamHandler(w http.ResponseWriter, req *http.Request)
EventStreamHandler endpoint is used for streaming events to the frontend
func (*Handler) FetchResultsHandler ¶ added in v0.0.6
func (h *Handler) FetchResultsHandler(w http.ResponseWriter, req *http.Request)
FetchResultsHandler fetchs pages of results from SaaS and presents it to the UI
func (*Handler) GetAllAdaptersHandler ¶ added in v0.0.6
func (h *Handler) GetAllAdaptersHandler(w http.ResponseWriter, req *http.Request)
GetAllAdaptersHandler is used to fetch all the adapters
func (*Handler) GetContextsFromK8SConfig ¶ added in v0.0.6
func (h *Handler) GetContextsFromK8SConfig(w http.ResponseWriter, req *http.Request)
GetContextsFromK8SConfig returns the context list for a given k8s config
func (*Handler) GrafanaBoardImportForPrometheusHandler ¶ added in v0.0.6
func (h *Handler) GrafanaBoardImportForPrometheusHandler(w http.ResponseWriter, req *http.Request)
GrafanaBoardImportForPrometheusHandler accepts a Grafana board json, parses it and returns the list of panels
func (*Handler) GrafanaBoardsHandler ¶ added in v0.0.6
func (h *Handler) GrafanaBoardsHandler(w http.ResponseWriter, req *http.Request)
GrafanaBoardsHandler is used for fetching Grafana boards and panels
func (*Handler) GrafanaConfigHandler ¶ added in v0.0.6
func (h *Handler) GrafanaConfigHandler(w http.ResponseWriter, req *http.Request)
GrafanaConfigHandler is used for persisting or removing Grafana configuration
func (*Handler) GrafanaQueryHandler ¶ added in v0.0.6
func (h *Handler) GrafanaQueryHandler(w http.ResponseWriter, req *http.Request)
GrafanaQueryHandler is used for handling Grafana queries
func (*Handler) GrafanaQueryRangeHandler ¶ added in v0.0.6
func (h *Handler) GrafanaQueryRangeHandler(w http.ResponseWriter, req *http.Request)
GrafanaQueryRangeHandler is used for handling Grafana Range queries
func (*Handler) K8SConfigHandler ¶ added in v0.0.4
func (h *Handler) K8SConfigHandler(w http.ResponseWriter, req *http.Request)
K8SConfigHandler is used for persisting kubernetes config and context info
func (*Handler) LoadTestHandler ¶ added in v0.0.4
func (h *Handler) LoadTestHandler(w http.ResponseWriter, req *http.Request)
LoadTestHandler runs the load test with the given parameters
func (*Handler) LoginHandler ¶ added in v0.0.4
func (h *Handler) LoginHandler(w http.ResponseWriter, r *http.Request)
LoginHandler redirects user for auth or issues session
func (*Handler) LogoutHandler ¶ added in v0.0.4
func (h *Handler) LogoutHandler(w http.ResponseWriter, req *http.Request)
LogoutHandler destroys the session on POSTs and redirects to home.
func (*Handler) MeshAdapterConfigHandler ¶ added in v0.0.6
func (h *Handler) MeshAdapterConfigHandler(w http.ResponseWriter, req *http.Request)
MeshAdapterConfigHandler is used to persist adapter config
func (*Handler) MeshOpsHandler ¶ added in v0.0.4
func (h *Handler) MeshOpsHandler(w http.ResponseWriter, req *http.Request)
MeshOpsHandler is used to send operations to the adapters
func (*Handler) PrometheusConfigHandler ¶ added in v0.0.6
func (h *Handler) PrometheusConfigHandler(w http.ResponseWriter, req *http.Request)
PrometheusConfigHandler is used for persisting prometheus configuration
func (*Handler) PrometheusQueryHandler ¶ added in v0.0.6
func (h *Handler) PrometheusQueryHandler(w http.ResponseWriter, req *http.Request)
PrometheusQueryHandler handles prometheus queries
func (*Handler) PrometheusQueryRangeHandler ¶ added in v0.0.6
func (h *Handler) PrometheusQueryRangeHandler(w http.ResponseWriter, req *http.Request)
PrometheusQueryRangeHandler handles prometheus range queries
func (*Handler) PrometheusStaticBoardHandler ¶ added in v0.0.6
func (h *Handler) PrometheusStaticBoardHandler(w http.ResponseWriter, req *http.Request)
PrometheusStaticBoardHandler returns the static board
func (*Handler) SaveSelectedGrafanaBoardsHandler ¶ added in v0.0.6
func (h *Handler) SaveSelectedGrafanaBoardsHandler(w http.ResponseWriter, req *http.Request)
SaveSelectedGrafanaBoardsHandler is used to persist board and panel selection
func (*Handler) SaveSelectedPrometheusBoardsHandler ¶ added in v0.0.6
func (h *Handler) SaveSelectedPrometheusBoardsHandler(w http.ResponseWriter, req *http.Request)
SaveSelectedPrometheusBoardsHandler persists selected board and panels
func (*Handler) SessionSyncHandler ¶ added in v0.0.6
func (h *Handler) SessionSyncHandler(w http.ResponseWriter, req *http.Request)
SessionSyncHandler is used to send session data to the UI for initial sync
func (*Handler) UserHandler ¶ added in v0.0.4
func (h *Handler) UserHandler(w http.ResponseWriter, req *http.Request)
UserHandler returns info about the logged in user