Skip to content

Commit ace81ba

Browse files
committed
Don't exclude some ingesters from metrics and http admin page
1 parent 16112e4 commit ace81ba

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

pkg/ring/http.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ func (r *Ring) ServeHTTP(w http.ResponseWriter, req *http.Request) {
102102
ing := r.ringDesc.Ingesters[id]
103103
timestamp := time.Unix(ing.Timestamp, 0)
104104
state := ing.State.String()
105-
if !r.IsHealthy(ing, Write) {
105+
if !r.IsHealthy(ing, Reporting) {
106106
state = unhealthy
107107
}
108108

pkg/ring/ring.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ type Operation int
4848
const (
4949
Read Operation = iota
5050
Write
51+
Reporting // Special value for inquiring about health
5152
)
5253

5354
type uint32s []uint32
@@ -325,7 +326,7 @@ func (r *Ring) Collect(ch chan<- prometheus.Metric) {
325326
JOINING.String(): 0,
326327
}
327328
for _, ingester := range r.ringDesc.Ingesters {
328-
if !r.IsHealthy(ingester, Write) {
329+
if !r.IsHealthy(ingester, Reporting) {
329330
byState[unhealthy]++
330331
} else {
331332
byState[ingester.State.String()]++

0 commit comments

Comments
 (0)