File tree 1 file changed +3
-13
lines changed
1 file changed +3
-13
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,7 @@ func (s *Statter) HostMemory() (*Result, error) {
124
124
// by checking /proc/1/stat.
125
125
func (s * Statter ) Uptime () (* Result , error ) {
126
126
r := & Result {
127
- Unit : "seconds " ,
127
+ Unit : "minutes " ,
128
128
Total : nil , // Is time a finite quantity? For this purpose, no.
129
129
}
130
130
@@ -137,19 +137,9 @@ func (s *Statter) Uptime() (*Result, error) {
137
137
if err != nil {
138
138
return nil , xerrors .Errorf ("get pid 1 stat: %w" , err )
139
139
}
140
- r .Used = time .Since (procInfo .StartTime ).Seconds ()
140
+ r .Used = time .Since (procInfo .StartTime ).Minutes ()
141
141
return r , nil
142
142
}
143
- r .Used = s .hi .Info ().Uptime ().Seconds ()
143
+ r .Used = s .hi .Info ().Uptime ().Minutes ()
144
144
return r , nil
145
145
}
146
-
147
- // ContainerCPU returns the CPU usage of the container.
148
- func (s * Statter ) ContainerCPU () (* Result , error ) {
149
- return nil , xerrors .Errorf ("not implemented" )
150
- }
151
-
152
- // ContainerMemory returns the memory usage of the container.
153
- func (s * Statter ) ContainerMemory () (* Result , error ) {
154
- return nil , xerrors .Errorf ("not implemented" )
155
- }
You can’t perform that action at this time.
0 commit comments