Comments and Typo Fixes

This commit is contained in:
Goutham Veeramachaneni 2017-03-06 17:16:37 +05:30
parent 6aee1551e1
commit 6634984a38
No known key found for this signature in database
GPG Key ID: F1C217E8E9023CAD
2 changed files with 8 additions and 4 deletions

View File

@ -59,7 +59,7 @@ var (
Namespace: namespace,
Subsystem: subsystem,
Name: "query_duration_seconds",
Help: "Query timmings",
Help: "Query timings",
ConstLabels: prometheus.Labels{"slice": "prepare_time"},
},
)
@ -68,7 +68,7 @@ var (
Namespace: namespace,
Subsystem: subsystem,
Name: "query_duration_seconds",
Help: "Query timmings",
Help: "Query timings",
ConstLabels: prometheus.Labels{"slice": "inner_eval"},
},
)
@ -77,7 +77,7 @@ var (
Namespace: namespace,
Subsystem: subsystem,
Name: "query_duration_seconds",
Help: "Query timmings",
Help: "Query timings",
ConstLabels: prometheus.Labels{"slice": "result_append"},
},
)
@ -86,7 +86,7 @@ var (
Namespace: namespace,
Subsystem: subsystem,
Name: "query_duration_seconds",
Help: "Query timmings",
Help: "Query timings",
ConstLabels: prometheus.Labels{"slice": "result_sort"},
},
)

View File

@ -345,6 +345,7 @@ func (api *API) dropSeries(r *http.Request) (interface{}, *apiError) {
return res, nil
}
// Target has the information for 1 target.
type Target struct {
// Labels before any processing.
DiscoveredLabels model.LabelSet `json:"discoveredLabels"`
@ -358,6 +359,7 @@ type Target struct {
Health retrieval.TargetHealth `json:"health"`
}
// TargetDiscovery has all the active targets.
type TargetDiscovery struct {
ActiveTargets []*Target `json:"activeTargets"`
}
@ -386,10 +388,12 @@ func (api *API) targets(r *http.Request) (interface{}, *apiError) {
return res, nil
}
// AlertmanagerDiscovery has all the active alert-managers
type AlertmanagerDiscovery struct {
ActiveAlertmanagers []*AlertmanagerTarget `json:"activeAlertmanagers"`
}
// AlertmanagerTarget has info on 1 AM
type AlertmanagerTarget struct {
URL string `json:"url"`
}