Documentation
¶
Index ¶
- type MetricsService
- func (serv MetricsService) Metrics(w http.ResponseWriter, r *http.Request)
- func (serv MetricsService) Query(w http.ResponseWriter, r *http.Request)
- func (serv MetricsService) QueryRange(w http.ResponseWriter, r *http.Request)
- func (msrv *MetricsService) RegisterHandler()
- func (serv MetricsService) SetTargets(w http.ResponseWriter, r *http.Request)
- type TargetGroup
- Bugs
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MetricsService ¶
type MetricsService struct {
Config *config.Config
TargetManager retrieval.TargetManager
Storage local.Storage
// contains filtered or unexported fields
}
MetricsService manages the /api HTTP endpoint.
func (MetricsService) Metrics ¶
func (serv MetricsService) Metrics(w http.ResponseWriter, r *http.Request)
Metrics handles the /api/metrics endpoint.
func (MetricsService) Query ¶
func (serv MetricsService) Query(w http.ResponseWriter, r *http.Request)
Query handles the /api/query endpoint.
func (MetricsService) QueryRange ¶
func (serv MetricsService) QueryRange(w http.ResponseWriter, r *http.Request)
QueryRange handles the /api/query_range endpoint.
func (*MetricsService) RegisterHandler ¶
func (msrv *MetricsService) RegisterHandler()
RegisterHandler registers the handler for the various endpoints below /api.
func (MetricsService) SetTargets ¶
func (serv MetricsService) SetTargets(w http.ResponseWriter, r *http.Request)
SetTargets handles the /api/targets endpoint.
type TargetGroup ¶
type TargetGroup struct {
Endpoints []string `json:"endpoints"`
BaseLabels map[string]string `json:"baseLabels"`
}
TargetGroup bundles endpoints and base labels with appropriate JSON annotations.
Notes ¶
Bugs ¶
Use Content-Type negotiation.
Validate that this ScrapeInterval is in fact the proper one for the job.
Click to show internal directories.
Click to hide internal directories.