mirror of https://github.com/apache/jclouds.git
Fix bug in parsing VirtualMachine.cpuUsed
This commit is contained in:
parent
da56c047a1
commit
6d657b1c90
|
@ -478,7 +478,7 @@ public class VirtualMachine implements Comparable<VirtualMachine> {
|
||||||
* @return the amount of the vm's CPU currently used
|
* @return the amount of the vm's CPU currently used
|
||||||
*/
|
*/
|
||||||
public float getCpuUsed() {
|
public float getCpuUsed() {
|
||||||
return cpuUsed != null ? Float.parseFloat(cpuUsed.substring(9, cpuUsed.length() - 1)) : 0.0f;
|
return cpuUsed != null ? Float.parseFloat(cpuUsed.substring(0, cpuUsed.length() - 1)) : 0.0f;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue