diff --git a/developer/developer-prefill.sql b/developer/developer-prefill.sql index c2d4f4357d8..89d9c7ebe28 100644 --- a/developer/developer-prefill.sql +++ b/developer/developer-prefill.sql @@ -62,22 +62,6 @@ INSERT INTO `cloud`.`configuration` (category, instance, component, name, value) VALUES ('Advanced', 'DEFAULT', 'management-server', 'expunge.interval', '60'); -INSERT INTO `cloud`.`configuration` (category, instance, component, name, value) - VALUES ('Advanced', 'DEFAULT', 'management-server', - 'cluster.cpu.allocated.capacity.disablethreshold', '0.95'); - -INSERT INTO `cloud`.`configuration` (category, instance, component, name, value) - VALUES ('Advanced', 'DEFAULT', 'management-server', - 'cluster.memory.allocated.capacity.disablethreshold ', '0.95'); - -INSERT INTO `cloud`.`configuration` (category, instance, component, name, value) - VALUES ('Advanced', 'DEFAULT', 'management-server', - 'pool.storage.allocated.capacity.disablethreshold ', '0.95'); - -INSERT INTO `cloud`.`configuration` (category, instance, component, name, value) - VALUES ('Advanced', 'DEFAULT', 'management-server', - 'pool.storage.capacity.disablethreshold ', '0.95'); - -- Add developer configuration entry; allows management server to be run as a user other than "cloud" INSERT INTO `cloud`.`configuration` (category, instance, component, name, value) VALUES ('Advanced', 'DEFAULT', 'management-server', diff --git a/server/src/com/cloud/server/ManagementServerImpl.java b/server/src/com/cloud/server/ManagementServerImpl.java index 3f8f52f5852..e61a9f42dc0 100644 --- a/server/src/com/cloud/server/ManagementServerImpl.java +++ b/server/src/com/cloud/server/ManagementServerImpl.java @@ -1709,9 +1709,18 @@ public class ManagementServerImpl extends ManagerBase implements ManagementServe List configVOList = new ArrayList(); for (ConfigurationVO param : result.first()) { ConfigurationVO configVo = _configDao.findByName(param.getName()); - configVo.setValue(_configDepot.get(param.getName()).valueIn(id).toString()); - configVOList.add(configVo); - } + if (configVo != null) { + ConfigKey key = _configDepot.get(param.getName()); + if (key != null) { + configVo.setValue(key.valueIn(id).toString()); + configVOList.add(configVo); + } else { + s_logger.warn("ConfigDepot could not find parameter " + param.getName() + " for scope " + scope); + } + } else { + s_logger.warn("Configuration item " + param.getName() + " not found in " + scope); + } + } return new Pair, Integer>(configVOList, configVOList.size()); }