Repository: cloudstack
Updated Branches:
  refs/heads/master 384025f25 -> 9fb2a760c


CLOUDSTACK-300: Creation of compute offering allow combination of local storage 
+ HA


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/9fb2a760
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/9fb2a760
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/9fb2a760

Branch: refs/heads/master
Commit: 9fb2a760c69a87013392b3b55c827d32fbad63db
Parents: 384025f
Author: Saksham Srivastava <saksham.srivast...@citrix.com>
Authored: Tue Aug 26 14:44:49 2014 +0530
Committer: Saksham Srivastava <saksham.srivast...@citrix.com>
Committed: Tue Aug 26 14:48:51 2014 +0530

----------------------------------------------------------------------
 .../src/com/cloud/configuration/ConfigurationManagerImpl.java  | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/9fb2a760/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java 
b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
index 9cef442..3328b7c 100755
--- a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
+++ b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
@@ -2006,17 +2006,21 @@ public class ConfigurationManagerImpl extends 
ManagerBase implements Configurati
             throw new InvalidParameterValueException("Please specify a valid 
domain id");
         }
 
+        Boolean offerHA = cmd.getOfferHa();
+
         boolean localStorageRequired = false;
         String storageType = cmd.getStorageType();
         if (storageType != null) {
             if 
(storageType.equalsIgnoreCase(ServiceOffering.StorageType.local.toString())) {
+                if(offerHA) {
+                    throw new InvalidParameterValueException("HA offering with 
local storage is not supported. ");
+                }
                 localStorageRequired = true;
             } else if 
(!storageType.equalsIgnoreCase(ServiceOffering.StorageType.shared.toString())) {
                 throw new InvalidParameterValueException("Invalid storage type 
" + storageType + " specified, valid types are: 'local' and 'shared'");
             }
         }
 
-        Boolean offerHA = cmd.getOfferHa();
         Boolean limitCpuUse = cmd.GetLimitCpuUse();
         Boolean volatileVm = cmd.getVolatileVm();
 

Reply via email to