- stats unixStats
- opsCounters *prometheus.CounterVec
- errCounters *prometheus.CounterVec
- ioBytes *prometheus.CounterVec
-}
-
-func (o *osWithStats) tickErr(err error) {
- if err == nil || o.errCounters == nil {
- return
- }
- o.errCounters.With(prometheus.Labels{"error_type": fmt.Sprintf("%T", err)}).Inc()
-}
-
-func (o *osWithStats) promSetup(opsC, errC, ioB *prometheus.CounterVec) {
- o.opsCounters = opsC
- o.errCounters = errC
- o.ioBytes = ioB