You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by ja...@apache.org on 2013/07/19 11:23:16 UTC

git commit: updated refs/heads/master to 499b78b

Updated Branches:
  refs/heads/master bd54fa13a -> 499b78bf0


CLOUDSTACK-3601: Adding router.template.xen/vmware/kvm/lxc/hyperv parameters in upgrade setup

Signed-off-by: Jayapal <ja...@apache.org>


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

Branch: refs/heads/master
Commit: 499b78bf09c19da7d759eb78e803278dff36e9b5
Parents: bd54fa1
Author: Harikrishna Patnala <ha...@citrix.com>
Authored: Thu Jul 18 11:16:25 2013 +0530
Committer: Jayapal <ja...@apache.org>
Committed: Fri Jul 19 14:40:13 2013 +0530

----------------------------------------------------------------------
 engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java | 8 ++++----
 setup/db/db/schema-410to420.sql                              | 6 ++++++
 2 files changed, 10 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/499b78bf/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java b/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java
index 2303ca8..0cf6b5b 100644
--- a/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java
+++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java
@@ -248,10 +248,10 @@ public class Upgrade410to420 implements DbUpgrade {
                         pstmt.executeUpdate();
                         pstmt.close();
                         // Change value of global configuration parameter router.template.* for the corresponding hypervisor
-                        pstmt = conn.prepareStatement("INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', ?, ?, 'Name of the default router template on Xenserver')");
-                        pstmt.setString(1, routerTemplateConfigurationNames.get(hypervisorAndTemplateName.getKey()));
-                        pstmt.setString(2, hypervisorAndTemplateName.getValue());
-                        pstmt.execute();
+                        pstmt = conn.prepareStatement("UPDATE `cloud`.`configuration` SET value = ? WHERE name = ?");
+                        pstmt.setString(1, hypervisorAndTemplateName.getValue());
+                        pstmt.setString(2, routerTemplateConfigurationNames.get(hypervisorAndTemplateName.getKey()));
+                        pstmt.executeUpdate();
                         pstmt.close();
                     } else {
                         if (hypervisorsListInUse.contains(hypervisorAndTemplateName.getKey())){

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/499b78bf/setup/db/db/schema-410to420.sql
----------------------------------------------------------------------
diff --git a/setup/db/db/schema-410to420.sql b/setup/db/db/schema-410to420.sql
index 47fd4bd..596723c 100644
--- a/setup/db/db/schema-410to420.sql
+++ b/setup/db/db/schema-410to420.sql
@@ -2177,6 +2177,12 @@ INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'manag
 INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'interval.baremetal.securitygroup.agent.echo', 10, 'Interval to echo baremetal security group agent, in seconds');
 INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'timeout.baremetal.securitygroup.agent.echo', 3600, 'Timeout to echo baremetal security group agent, in seconds, the provisioning process will be treated as a failure');
 
+INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', 'router.template.hyperv', 'SystemVM Template (HyperV)', 'Name of the default router template on Hyperv.');
+INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', 'router.template.kvm', 'SystemVM Template (KVM)', 'Name of the default router template on KVM.');
+INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', 'router.template.lxc', 'SystemVM Template (LXC)', 'Name of the default router template on LXC.');
+INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', 'router.template.vmware', 'SystemVM Template (vSphere)', 'Name of the default router template on Vmware.');
+INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'NetworkManager', 'router.template.xen', 'SystemVM Template (XenServer)', 'Name of the default router template on Xenserver.');
+
 alter table `cloud`.`network_offerings` add column egress_default_policy boolean default false;
 
 -- Add stratospher ssp tables