Fix DB warnings - txn: Commit called when it is not a transaction: -NetworkServiceImpl.dedicateGuestVlanRange:3050
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/e7d5ccaa Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/e7d5ccaa Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/e7d5ccaa Branch: refs/heads/disk_io_throttling Commit: e7d5ccaada697607260ab5ee8e8ff3b436973f88 Parents: 6208a51 Author: Likitha Shetty <likitha.she...@citrix.com> Authored: Fri Jun 7 12:11:15 2013 +0530 Committer: Likitha Shetty <likitha.she...@citrix.com> Committed: Fri Jun 7 12:12:18 2013 +0530 ---------------------------------------------------------------------- server/src/com/cloud/network/NetworkServiceImpl.java | 1 + 1 file changed, 1 insertion(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/e7d5ccaa/server/src/com/cloud/network/NetworkServiceImpl.java ---------------------------------------------------------------------- diff --git a/server/src/com/cloud/network/NetworkServiceImpl.java b/server/src/com/cloud/network/NetworkServiceImpl.java index 2bf9f40..29a36b9 100755 --- a/server/src/com/cloud/network/NetworkServiceImpl.java +++ b/server/src/com/cloud/network/NetworkServiceImpl.java @@ -3044,6 +3044,7 @@ public class NetworkServiceImpl extends ManagerBase implements NetworkService { _accountGuestVlanMapDao.update(guestVlanMapId, accountGuestVlanMapVO); } else { Transaction txn = Transaction.currentTxn(); + txn.start(); accountGuestVlanMapVO = new AccountGuestVlanMapVO(vlanOwner.getAccountId(), physicalNetworkId); accountGuestVlanMapVO.setGuestVlanRange(startVlan + "-" + endVlan); _accountGuestVlanMapDao.persist(accountGuestVlanMapVO);