Vered Volansky has uploaded a new change for review.

Change subject: core: deprecate old storage allocation checks.
......................................................................

core: deprecate old storage allocation checks.

According to bz, deprecated existing storage allocation validations so
that new patches use the new and correct sotrage allocation checks,
until such time the old validations are all replaced in the existing code
and can be removed.

Change-Id: Ie1fc08b4375eaea0e99593938adac48c5e2d9387
Bug-Url: https://bugzilla.redhat.com/960934
Signed-off-by: Vered Volansky <[email protected]>
---
M 
backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/StorageDomainValidator.java
1 file changed, 24 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/97/28897/1

diff --git 
a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/StorageDomainValidator.java
 
b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/StorageDomainValidator.java
index 40294ee..7f7d554 100644
--- 
a/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/StorageDomainValidator.java
+++ 
b/backend/manager/modules/bll/src/main/java/org/ovirt/engine/core/bll/validator/StorageDomainValidator.java
@@ -61,10 +61,22 @@
         return String.format("$%1$s %2$s", "storageName", 
storageDomain.getStorageName());
     }
 
+    /**
+     * @deprecated
+     * This validation is replaced by 
hadSpaceForClonedDisks,hadSpaceForClonedDisk, HasSpaceForNewDisks and
+     * HasSpaceForNewDisk, according to the situation.
+     */
+    @Deprecated
     public ValidationResult isDomainHasSpaceForRequest(final long 
requestedSize) {
         return isDomainHasSpaceForRequest(requestedSize, true);
     }
 
+    /**
+     * @deprecated
+     * This validation is replaced by 
hadSpaceForClonedDisks,hadSpaceForClonedDisk, HasSpaceForNewDisks and
+     * HasSpaceForNewDisk, according to the situation.
+     */
+    @Deprecated
     public ValidationResult isDomainHasSpaceForRequest(final long 
requestedSize, final boolean useThresHold) {
         long size = useThresHold ? getLowDiskSpaceThreshold() : 0L;
         if (storageDomain.getAvailableDiskSize() != null &&
@@ -158,6 +170,12 @@
                 storageName());
     }
 
+    /**
+     * @deprecated
+     * This validation is replaced by 
hadSpaceForClonedDisks,hadSpaceForClonedDisk, HasSpaceForNewDisks and
+     * HasSpaceForNewDisk, according to the situation.
+     */
+    @Deprecated
     public static Map<StorageDomain, Integer> 
getSpaceRequirementsForStorageDomains(Collection<DiskImage> images,
             Map<Guid, StorageDomain> storageDomains, Map<Guid, DiskImage> 
imageToDestinationDomainMap) {
         Map<DiskImage, StorageDomain> spaceMap = new HashMap<DiskImage, 
StorageDomain>();
@@ -172,6 +190,12 @@
         return 
StorageDomainValidator.getSpaceRequirementsForStorageDomains(spaceMap);
     }
 
+    /**
+     * @deprecated
+     * This validation is replaced by 
hadSpaceForClonedDisks,hadSpaceForClonedDisk, HasSpaceForNewDisks and
+     * HasSpaceForNewDisk, according to the situation.
+     */
+    @Deprecated
     public static Map<StorageDomain, Integer> 
getSpaceRequirementsForStorageDomains(Map<DiskImage, StorageDomain> 
imageToDomainMap) {
         Map<StorageDomain, Integer> map = new HashMap<StorageDomain, 
Integer>();
         if (!imageToDomainMap.isEmpty()) {


-- 
To view, visit http://gerrit.ovirt.org/28897
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie1fc08b4375eaea0e99593938adac48c5e2d9387
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: ovirt-engine-3.4
Gerrit-Owner: Vered Volansky <[email protected]>
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to