cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sate...@apache.org
Subject [08/14] git commit: updated refs/heads/vmware-disk-controllers to 85bd96c
Date Wed, 07 Jan 2015 10:17:29 GMT
Close transaction while fetching recent events


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

Branch: refs/heads/vmware-disk-controllers
Commit: 438f90a2627c4a7408f02fc4b59be7eb566443be
Parents: 9eb8d53
Author: Kishan Kavala <kishan@apache.org>
Authored: Fri Nov 21 15:14:26 2014 +0530
Committer: Kishan Kavala <kishan@apache.org>
Committed: Wed Jan 7 14:14:44 2015 +0530

----------------------------------------------------------------------
 engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/438f90a2/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java
----------------------------------------------------------------------
diff --git a/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java b/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java
index 4e35bf5..1739254 100644
--- a/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java
+++ b/engine/schema/src/com/cloud/event/dao/UsageEventDaoImpl.java
@@ -124,6 +124,8 @@ public class UsageEventDaoImpl extends GenericDaoBase<UsageEventVO,
Long> implem
             txn.rollback();
             s_logger.error("error copying events from cloud db to usage db", ex);
             throw new CloudRuntimeException(ex.getMessage());
+        } finally {
+            txn.close();
         }
 
         // Copy event details from cloud db to usage db
@@ -150,6 +152,8 @@ public class UsageEventDaoImpl extends GenericDaoBase<UsageEventVO,
Long> implem
             txn.rollback();
             s_logger.error("error copying event details from cloud db to usage db", ex);
             throw new CloudRuntimeException(ex.getMessage());
+        } finally {
+            txn.close();
         }
 
         return findRecentEvents(endDate);


Mime
View raw message