mirror of
https://github.com/ClusterCockpit/cc-metric-collector.git
synced 2024-11-10 04:27:25 +01:00
Fix for servers, which do not set status.state for thermals or powercontrols
This commit is contained in:
parent
a8beec29cc
commit
60ef0ed116
@ -78,7 +78,7 @@ func (r *RedfishReceiver) readThermalMetrics(
|
||||
}
|
||||
|
||||
// Skip all temperatures which are not in enabled state
|
||||
if temperature.Status.State != common.EnabledState {
|
||||
if temperature.Status.State != "" && temperature.Status.State != common.EnabledState {
|
||||
continue
|
||||
}
|
||||
|
||||
@ -212,7 +212,7 @@ func (r *RedfishReceiver) readPowerMetrics(
|
||||
for _, pc := range power.PowerControl {
|
||||
|
||||
// Skip all power controls which are not in enabled state
|
||||
if pc.Status.State != common.EnabledState {
|
||||
if pc.Status.State != "" && pc.Status.State != common.EnabledState {
|
||||
continue
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user