cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sate...@apache.org
Subject [35/50] [abbrv] git commit: updated refs/heads/vmware-storage-motion to 202b103
Date Fri, 24 May 2013 16:28:50 GMT
CLOUDSTACK-2664: Fixed delete query. Added log message when CloudRuntimeException is thrown
during upgrade


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

Branch: refs/heads/vmware-storage-motion
Commit: 3b48299a0395916ad3dc8a95b6d98afd96ecf251
Parents: 3e02a76
Author: Kishan Kavala <kishan@cloud.com>
Authored: Fri May 24 12:37:09 2013 +0530
Committer: Kishan Kavala <kishan@cloud.com>
Committed: Fri May 24 12:37:18 2013 +0530

----------------------------------------------------------------------
 .../com/cloud/upgrade/DatabaseUpgradeChecker.java  |    5 ++++-
 .../src/com/cloud/upgrade/dao/Upgrade410to420.java |    2 +-
 2 files changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/3b48299a/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java b/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java
index 9bc0ba5..e23815b 100755
--- a/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java
+++ b/engine/schema/src/com/cloud/upgrade/DatabaseUpgradeChecker.java
@@ -261,7 +261,10 @@ public class DatabaseUpgradeChecker implements SystemIntegrityChecker
{
                 }
 
                 txn.commit();
-            } finally {
+            } catch (CloudRuntimeException e){
+                s_logger.error("Unable to upgrade the database", e);
+                throw new CloudRuntimeException("Unable to upgrade the database", e);
+            }finally {
                 txn.close();
             }
         }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/3b48299a/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 95abe5f..f28d496 100644
--- a/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java
+++ b/engine/schema/src/com/cloud/upgrade/dao/Upgrade410to420.java
@@ -759,7 +759,7 @@ public class Upgrade410to420 implements DbUpgrade {
             while (rs.next()) {
                 long id = rs.getLong(1);
                 // remove Firewall service for SG shared network offering
-                pstmt = conn.prepareStatement("DELETE `cloud`.`ntwk_offering_service_map`
where network_offering_id=? and service='Firewall'");
+                pstmt = conn.prepareStatement("DELETE from `cloud`.`ntwk_offering_service_map`
where network_offering_id=? and service='Firewall'");
                 pstmt.setLong(1, id);
                 pstmt.executeUpdate();
             }


Mime
View raw message