Negative total cpu time reported by the node stats REST API, closes #1297.
This commit is contained in:
parent
8facdb2e3d
commit
63f2e84535
|
@ -56,6 +56,7 @@ public class SigarProcessProbe extends AbstractComponent implements ProcessProbe
|
||||||
stats.cpu.percent = (short) (cpu.getPercent() * 100);
|
stats.cpu.percent = (short) (cpu.getPercent() * 100);
|
||||||
stats.cpu.sys = cpu.getSys();
|
stats.cpu.sys = cpu.getSys();
|
||||||
stats.cpu.user = cpu.getUser();
|
stats.cpu.user = cpu.getUser();
|
||||||
|
stats.cpu.total = cpu.getTotal();
|
||||||
} catch (SigarException e) {
|
} catch (SigarException e) {
|
||||||
// ignore
|
// ignore
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue