File tree Expand file tree Collapse file tree 1 file changed +12
-9
lines changed Expand file tree Collapse file tree 1 file changed +12
-9
lines changed Original file line number Diff line number Diff line change @@ -189,16 +189,19 @@ def addMeasurement(self, meassure):
189
189
def __str__ (self ):
190
190
# dd = '-a' if self.includeDiskData else ''
191
191
# Workaround for RTC Defect 280368: Zimon capacity query does not return all results (seen on CNSA)
192
- if (self .metrics
193
- and any (str (metric ) in self .DISK_CAP_METRICS for metric in self .metrics )
194
- ) or (self .sensor
195
- and self .sensor in ("GPFSDiskCap" , "GPFSPoolCap" , "GPFSInodeCap" )
196
- ):
197
- dd = '-ar'
198
- elif self .includeDiskData :
192
+ dd = ''
193
+ if self .includeDiskData :
199
194
dd = '-a'
200
- else :
201
- dd = ''
195
+ if self .metrics :
196
+ for metric in self .metrics :
197
+ if any (map (metric .__contains__ , self .DISK_CAP_METRICS )):
198
+ dd = '-ar'
199
+ break
200
+ elif (self .sensor and self .sensor in ("GPFSDiskCap" ,
201
+ "GPFSPoolCap" ,
202
+ "GPFSInodeCap" )
203
+ ):
204
+ dd = '-ar'
202
205
203
206
if self .rawData :
204
207
raw = '-z'
You can’t perform that action at this time.
0 commit comments