Opened 3 years ago
Closed 15 months ago
#387 closed enhancement (fixed)
Make CheckSystem::checkCounter go faster by handling multiple counters with a single sleep
| Reported by: | lovedada | Owned by: | mickem |
|---|---|---|---|
| Priority: | 5 | Milestone: | 0.4.0 |
| Component: | CheckSystem | Version: | 0.3.7 |
| Severity: | Feature Requests | Keywords: | |
| Cc: |
Description
Currently if I send over a list of say 5 counters in a checkCounter command, it will take at least 5 seconds (assuming averages=false is not used) because the method CheckSystem::checkCounter creates 5 separate queries and for each query adds one counter, collects data, sleeps for one second, collects data again and then concatenates the result to the value that will be returned. So there are 5 one second sleeps.
The suggested improvement is to reduce the delay to one second by creating one query, adding five counters, collecting data for all five, sleeping for one second, collecting data again for all 5 and then get concatenating and returning the results.
In my brief look at the source code it seems the PDHQuery class used has the capability already to add multiple counters.
Change History (4)
comment:1 Changed 3 years ago by mickem
- Milestone set to 0.3.x
comment:2 Changed 23 months ago by mickem
- Milestone changed from 0.3.x to 0.3.10
- Status changed from new to assigned
comment:3 Changed 15 months ago by mickem
- Milestone changed from 0.3.10 to 0.4.0
- Status changed from assigned to new
comment:4 Changed 15 months ago by mickem
- Resolution set to fixed
- Status changed from new to closed









Fixed in next RC for 0.4.0