Fix DB warnings - txn: Commit called when it is not a transaction: -NetworkServiceImpl.dedicateGuestVlanRange:3050

This commit is contained in:
Likitha Shetty 2013-06-07 12:11:15 +05:30
parent 6208a51283
commit e7d5ccaada
1 changed files with 1 additions and 0 deletions

View File

@ -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);