330331332333334335336337338339340
pstmt.addBatch(); } pstmt.executeBatch(); txn.commit(); } catch (Exception ex) { txn.rollback(); s_logger.error("error saving vm disk stats to cloud_usage db", ex); throw new CloudRuntimeException(ex.getMessage()); } }
376377378379380381382383384385386
443444445446447448449450451452453
pstmt.addBatch(); } pstmt.executeBatch(); txn.commit(); } catch (Exception ex) { txn.rollback(); s_logger.error("error saving usage records to cloud_usage db", ex); throw new CloudRuntimeException(ex.getMessage()); } } }
6364656667686970717273
pstmt.setLong(1, accountId); pstmt.setLong(2, volId); pstmt.executeUpdate(); txn.commit(); } catch (Exception e) { txn.rollback(); s_logger.warn("Error removing usageVolumeVO", e); } finally { txn.close(); } }
8586878889909192939495
pstmt.setLong(3, usage.getId()); } pstmt.executeUpdate(); txn.commit(); } catch (Exception e) { txn.rollback(); s_logger.warn("Error updating UsageVolumeVO", e); } finally { txn.close(); } }
163164165166167168169170171172173
} usageRecords.add(new UsageVolumeVO(vId, zoneId, acctId, dId, doId, tId, size, createdDate, deletedDate)); } } catch (Exception e) { txn.rollback(); s_logger.warn("Error getting usage records", e); } finally { txn.close(); }
6768697071727374757677
pstmt.setLong(4, usage.getSecurityGroupId()); } pstmt.executeUpdate(); txn.commit(); } catch (Exception e) { txn.rollback(); s_logger.warn("Error updating UsageSecurityGroupVO", e); } finally { txn.close(); } }
137138139140141142143144145146147
} usageRecords.add(new UsageSecurityGroupVO(zoneId, acctId, dId, vmId, sgId, createdDate, deletedDate)); } } catch (Exception e) { txn.rollback(); s_logger.warn("Error getting usage records", e); } finally { txn.close(); }
6162636465666768697071
pstmt.setLong(1, accountId); pstmt.setLong(2, lbId); pstmt.executeUpdate(); txn.commit(); } catch (Exception e) { txn.rollback(); s_logger.warn("Error removing UsageLoadBalancerPolicyVO", e); } finally { txn.close(); } }
8384858687888990919293
pstmt.setLong(3, usage.getId()); } pstmt.executeUpdate(); txn.commit(); } catch (Exception e) { txn.rollback(); s_logger.warn("Error updating UsageLoadBalancerPolicyVO", e); } finally { txn.close(); } }