From 90066f1c125fe1f58e2b7f2c9a5ab28a7f06379c Mon Sep 17 00:00:00 2001 From: Sheng Yang Date: Fri, 6 Jan 2012 13:43:54 -0800 Subject: [PATCH] Remove conserve-mode restriction Multiply provider can be used for conserve mode. --- .../ConfigurationManagerImpl.java | 25 ------------------- 1 file changed, 25 deletions(-) diff --git a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java index 56c3163d73d..7627604ecbe 100755 --- a/server/src/com/cloud/configuration/ConfigurationManagerImpl.java +++ b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java @@ -3030,31 +3030,6 @@ public class ConfigurationManagerImpl implements ConfigurationManager, Configura } } - //validate if conserve mode can be supported - if (conserveMode) { - boolean pass = true; - Iterator it = serviceProviderMap.entrySet().iterator(); - Set providers = new HashSet(); - while (it.hasNext()) { - Map.Entry pairs = (Map.Entry)it.next(); - Set v = (Set)pairs.getValue(); - if (v.size() == 0) { - continue; - } - if (v.size() > 1) { - pass = false; - break; - } - providers.add((Provider) v.toArray()[0]); - } - if (providers.size() != 1) { - pass = false; - } - if (!pass) { - throw new InvalidParameterValueException("Can't enable conserve mode for the network offering, due to multiply providers existed!"); - } - } - //validate providers combination here _networkMgr.canProviderSupportServices(providerCombinationToVerify);