The lowest the hypervisor snapshot reserve value can be is 10 (down from 50).

This commit is contained in:
Mike Tutkowski 2015-08-05 15:47:57 -06:00
parent 97eb0f7528
commit 2cbc168822
1 changed files with 2 additions and 3 deletions

View File

@ -77,6 +77,7 @@ import com.cloud.utils.exception.CloudRuntimeException;
public class SolidFirePrimaryDataStoreDriver implements PrimaryDataStoreDriver {
private static final Logger s_logger = Logger.getLogger(SolidFirePrimaryDataStoreDriver.class);
private static final int s_lockTimeInSeconds = 300;
private static final int s_lowestHypervisorSnapshotReserve = 10;
@Inject private AccountDao _accountDao;
@Inject private AccountDetailsDao _accountDetailsDao;
@ -352,9 +353,7 @@ public class SolidFirePrimaryDataStoreDriver implements PrimaryDataStoreDriver {
Integer hypervisorSnapshotReserve = volume.getHypervisorSnapshotReserve();
if (hypervisorSnapshotReserve != null) {
if (hypervisorSnapshotReserve < 50) {
hypervisorSnapshotReserve = 50;
}
hypervisorSnapshotReserve = Math.max(hypervisorSnapshotReserve, s_lowestHypervisorSnapshotReserve);
volumeSize += volumeSize * (hypervisorSnapshotReserve / 100f);
}