SetApplicationUtilization records a measurement for a generic utilization metric.
(val float64)
| 238 | // SetApplicationUtilization records a measurement for a generic utilization |
| 239 | // metric. |
| 240 | func (s *serverMetricsRecorder) SetApplicationUtilization(val float64) { |
| 241 | if val < 0 { |
| 242 | if logger.V(2) { |
| 243 | logger.Infof("Ignoring Application Utilization value out of range: %v", val) |
| 244 | } |
| 245 | return |
| 246 | } |
| 247 | smCopy := copyServerMetrics(s.state.Load()) |
| 248 | smCopy.AppUtilization = val |
| 249 | s.state.Store(smCopy) |
| 250 | } |
| 251 | |
| 252 | // DeleteApplicationUtilization deletes the relevant server metric to prevent |
| 253 | // it from being sent. |
nothing calls this directly
no test coverage detected