Allon Mureinik has posted comments on this change.
Change subject: core: Quota refactor - QuotaManager
......................................................................
Patch Set 15: I would prefer that you didn't submit this
(2 inline comments)
....................................................
File
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/quota/QuotaManager.java
Line 331: }
Line 332: }
Line 333:
Line 334: private boolean
validateAndSetStorageQuotaHelper(QuotaConsumptionParametersWrapper parameters) {
Line 335: lock.readLock().lock();
you're modifying stuff - shouldn't there be a writeLock there somewhere?
Line 336: try {
Line 337: synchronized
(storagePoolQuotaMap.get(parameters.getAuditLogable().getStoragePool().getId()))
{
Line 338: if
(storagePoolQuotaMap.get(parameters.getAuditLogable().getStoragePool().getId())
== null) {
Line 339: return false;
Line 346:
Line 347: generateDesiredStorageSizeQuotaMap(parameters,
desiredStorageSizeQuotaMap);
Line 348:
Line 349: for (Guid quotaId :
desiredStorageSizeQuotaMap.keySet()) {
Line 350: Quota quota = quotaMap.get(quotaId);
just iterate over the entrySet
Line 351: if (quota.getGlobalQuotaStorage() != null) {
Line 352: if
(checkConsumptionForGlobalStorageQuota(parameters,
Line 353: desiredStorageSizeQuotaMap,
Line 354: newUsedGlobalStorageSize,
--
To view, visit http://gerrit.ovirt.org/8776
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ibb100467a55b26e4219d1a2562da86b81ffdc032
Gerrit-PatchSet: 15
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: ofri masad <[email protected]>
Gerrit-Reviewer: Allon Mureinik <[email protected]>
Gerrit-Reviewer: Doron Fediuck <[email protected]>
Gerrit-Reviewer: Gilad Chaplik <[email protected]>
Gerrit-Reviewer: Laszlo Hornyak <[email protected]>
Gerrit-Reviewer: Michael Kublin <[email protected]>
Gerrit-Reviewer: Sharad Mishra <[email protected]>
Gerrit-Reviewer: Yair Zaslavsky <[email protected]>
Gerrit-Reviewer: ofri masad <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches