mirror of
https://github.com/ClusterCockpit/cc-metric-collector.git
synced 2025-07-19 03:11:41 +02:00
Allow to shutdown redfish receiver during metric read
This commit is contained in:
@@ -146,7 +146,17 @@ func (r *RedfishReceiver) Start() {
|
||||
}
|
||||
|
||||
// Distribute client configs to workers
|
||||
clientConfigLoop:
|
||||
for i := range r.config.ClientConfigs {
|
||||
// Check done channel status
|
||||
select {
|
||||
case _, ok := <-r.done:
|
||||
if !ok {
|
||||
break clientConfigLoop
|
||||
}
|
||||
default:
|
||||
}
|
||||
|
||||
workerInput <- i
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user