recordReloadAttempt stamps the attempt-time gauge at the start of a Reload. A reload that hangs mid-flight is detected by watching the gap between this gauge and ProvidersLastReloadSuccessTimestampSeconds.
()
| 69 | // Reload. A reload that hangs mid-flight is detected by watching the |
| 70 | // gap between this gauge and ProvidersLastReloadSuccessTimestampSeconds. |
| 71 | func (s *Server) recordReloadAttempt() { |
| 72 | if s.metrics == nil { |
| 73 | return |
| 74 | } |
| 75 | s.metrics.ProvidersLastReloadTimestampSeconds.Set(float64(time.Now().Unix())) |
| 76 | } |
| 77 | |
| 78 | // recordReloadSuccess rewrites the provider_info GaugeVec from the |
| 79 | // classified reload and stamps the success-time gauge. Reset clears |