fix incorrect iscsi path stat for managed storage (#3181)

## Description
The issue was that an Incorrect iscsi path was being passed for managed storage pools when collecting volume stats. Storage pools normally have a UUID based path while managed storage pools require an IQN based path
This commit is contained in:
skattoju3 2019-03-29 05:25:01 -04:00 committed by dahn
parent 4985e57f30
commit beb0422dd5
1 changed files with 5 additions and 1 deletions

View File

@ -928,7 +928,11 @@ public class StatsCollector extends ManagerBase implements ComponentMethodInterc
List<String> volumeLocators = new ArrayList<String>();
for (VolumeVO volume : volumes) {
if (volume.getFormat() == ImageFormat.QCOW2) {
volumeLocators.add(volume.getUuid());
if (pool.isManaged()) {
volumeLocators.add(volume.getPath());
} else {
volumeLocators.add(volume.getUuid());
}
} else if (volume.getFormat() == ImageFormat.VHD) {
volumeLocators.add(volume.getPath());
} else if (volume.getFormat() == ImageFormat.OVA) {