Return-Path: X-Original-To: apmail-cloudstack-commits-archive@www.apache.org Delivered-To: apmail-cloudstack-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BDC8E181D8 for ; Wed, 5 Aug 2015 22:24:39 +0000 (UTC) Received: (qmail 78174 invoked by uid 500); 5 Aug 2015 22:24:39 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 78144 invoked by uid 500); 5 Aug 2015 22:24:39 -0000 Mailing-List: contact commits-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list commits@cloudstack.apache.org Received: (qmail 78134 invoked by uid 99); 5 Aug 2015 22:24:39 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Aug 2015 22:24:39 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 63CBDDFD87; Wed, 5 Aug 2015 22:24:39 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: mtutkowski@apache.org To: commits@cloudstack.apache.org Date: Wed, 05 Aug 2015 22:24:39 -0000 Message-Id: X-Mailer: ASF-Git Admin Mailer Subject: [1/2] git commit: updated refs/heads/master to abfe33a Repository: cloudstack Updated Branches: refs/heads/master 97eb0f752 -> abfe33a24 The lowest the hypervisor snapshot reserve value can be is 10 (down from 50). Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/2cbc1688 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/2cbc1688 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/2cbc1688 Branch: refs/heads/master Commit: 2cbc1688220b6af086ea4a367f2132d892a97cb9 Parents: 97eb0f7 Author: Mike Tutkowski Authored: Wed Aug 5 15:47:57 2015 -0600 Committer: Mike Tutkowski Committed: Wed Aug 5 15:47:57 2015 -0600 ---------------------------------------------------------------------- .../datastore/driver/SolidFirePrimaryDataStoreDriver.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/2cbc1688/plugins/storage/volume/solidfire/src/org/apache/cloudstack/storage/datastore/driver/SolidFirePrimaryDataStoreDriver.java ---------------------------------------------------------------------- diff --git a/plugins/storage/volume/solidfire/src/org/apache/cloudstack/storage/datastore/driver/SolidFirePrimaryDataStoreDriver.java b/plugins/storage/volume/solidfire/src/org/apache/cloudstack/storage/datastore/driver/SolidFirePrimaryDataStoreDriver.java index 62a03a4..46ecd69 100644 --- a/plugins/storage/volume/solidfire/src/org/apache/cloudstack/storage/datastore/driver/SolidFirePrimaryDataStoreDriver.java +++ b/plugins/storage/volume/solidfire/src/org/apache/cloudstack/storage/datastore/driver/SolidFirePrimaryDataStoreDriver.java @@ -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); }