will be reusing CpuInfo
This commit is contained in:
parent
1c75927eca
commit
7985dea967
|
@ -222,8 +222,13 @@ public class SigarRegistry extends AbstractMBean {
|
||||||
return;
|
return;
|
||||||
|
|
||||||
//CPU beans
|
//CPU beans
|
||||||
|
CpuInfo[] info;
|
||||||
try {
|
try {
|
||||||
CpuInfo[] info = sigar.getCpuInfoList();
|
info = sigar.getCpuInfoList();
|
||||||
|
} catch (SigarException e) {
|
||||||
|
throw unexpectedError("CpuInfoList", e);
|
||||||
|
}
|
||||||
|
|
||||||
for (int i=0; i<info.length; i++) {
|
for (int i=0; i<info.length; i++) {
|
||||||
String idx = String.valueOf(i);
|
String idx = String.valueOf(i);
|
||||||
ReflectedMBean mbean =
|
ReflectedMBean mbean =
|
||||||
|
@ -235,9 +240,6 @@ public class SigarRegistry extends AbstractMBean {
|
||||||
mbean.setType("CpuPercList");
|
mbean.setType("CpuPercList");
|
||||||
registerMBean(mbean);
|
registerMBean(mbean);
|
||||||
}
|
}
|
||||||
} catch (SigarException e) {
|
|
||||||
throw unexpectedError("CpuInfoList", e);
|
|
||||||
}
|
|
||||||
|
|
||||||
//FileSystem beans
|
//FileSystem beans
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in New Issue