You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by se...@apache.org on 2013/07/12 09:51:01 UTC
[06/50] git commit: updated refs/heads/sdnextensions to bcfb4e6
CLOUDSTACK-3301 NPE wile deployVM in kvm Only solidfire type PS is setting/using the capacityIops, This check will fix to return the storage has enough Iops when capacityIops is set to NULL for any PS Storage provider
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/7089e1ce
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/7089e1ce
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/7089e1ce
Branch: refs/heads/sdnextensions
Commit: 7089e1ce44151702f36a8135e3b74752631a1894
Parents: 7eb3d49
Author: Rajesh Battala <ra...@citrix.com>
Authored: Tue Jul 2 11:56:19 2013 +0530
Committer: Edison Su <su...@gmail.com>
Committed: Wed Jul 10 14:52:47 2013 -0700
----------------------------------------------------------------------
server/src/com/cloud/storage/StorageManagerImpl.java | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/7089e1ce/server/src/com/cloud/storage/StorageManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/storage/StorageManagerImpl.java b/server/src/com/cloud/storage/StorageManagerImpl.java
index d9ef853..7378708 100755
--- a/server/src/com/cloud/storage/StorageManagerImpl.java
+++ b/server/src/com/cloud/storage/StorageManagerImpl.java
@@ -1499,11 +1499,15 @@ public class StorageManagerImpl extends ManagerBase implements StorageManager, C
if (requestedVolumes == null || requestedVolumes.isEmpty() || pool == null) {
return false;
}
-
+ // Only Solidfire type primary storage is using/setting Iops.
+ // This check will fix to return the storage has enough Iops when capacityIops is set to NULL for any PS Storage provider
+ if (pool.getCapacityIops() == null ) {
+ return true;
+ }
long currentIops = 0;
-
List<VolumeVO> volumesInPool = _volumeDao.findByPoolId(pool.getId(), null);
+
for (VolumeVO volumeInPool : volumesInPool) {
Long minIops = volumeInPool.getMinIops();