示例#1
0
        void RefreshPinnedTailThreshold()
        {
            CLFS_MGMT_POLICY_LOGTAIL policy;

            UnsafeNativeMethods.QueryLogPolicy(this.store.Handle, out policy);

            if (policy.MinimumAvailablePercentage != 0)
            {
                this.pinnedTailThreshold = PolicyUnit.Percentage(
                    (int)policy.MinimumAvailablePercentage);
            }
            else
            {
                this.pinnedTailThreshold = PolicyUnit.Extents(
                    (int)policy.MinimumAvailableContainers);
            }
            this.modifiedFields &= ~ModifiedFields.PinnedTailThreshold;
        }
示例#2
0
        void RefreshGrowthRate()
        {
            CLFS_MGMT_POLICY_GROWTHRATE policy;

            UnsafeNativeMethods.QueryLogPolicy(this.store.Handle, out policy);

            if (policy.AbsoluteGrowthInContainers != 0)
            {
                this.growthRate = PolicyUnit.Extents(
                    (int)policy.AbsoluteGrowthInContainers);
            }
            else
            {
                this.growthRate = PolicyUnit.Percentage(
                    (int)policy.RelativeGrowthPercentage);
            }
            this.modifiedFields &= ~ModifiedFields.GrowthRate;
        }