countMidStreamResync records a client told MID-STREAM that it missed events, on a connection that stayed open (BUG-2730). Deliberately NOT countResumeGap: that counter's population is resumes this instance could not serve, and existing alerts are written against it. Widening it in place would have
(activity bool)
| 1419 | // changing their name, and a mixed-version fleet would report two populations |
| 1420 | // under one metric for the length of a rollout. |
| 1421 | func (s *Server) countMidStreamResync(activity bool) { |
| 1422 | if s.metrics == nil { |
| 1423 | return |
| 1424 | } |
| 1425 | if activity { |
| 1426 | s.metrics.EventMidstreamResyncsTotal.Inc() |
| 1427 | return |
| 1428 | } |
| 1429 | s.metrics.WatchMidstreamResyncsTotal.Inc() |
| 1430 | } |
| 1431 | |
| 1432 | // SetMetrics attaches Prometheus metrics to the server. |
| 1433 | // Must be called before the first request is served. |
no outgoing calls
no test coverage detected