protected internal override Org.Apache.Hadoop.Yarn.Api.Records.Resource GetPlanQueueCapacity
            (string planQueueName)
        {
            Org.Apache.Hadoop.Yarn.Api.Records.Resource minAllocation = GetMinAllocation();
            ResourceCalculator rescCalc  = GetResourceCalculator();
            CSQueue            planQueue = capScheduler.GetQueue(planQueueName);

            return(rescCalc.MultiplyAndNormalizeDown(capScheduler.GetClusterResource(), planQueue
                                                     .GetAbsoluteCapacity(), minAllocation));
        }
        protected internal override Org.Apache.Hadoop.Yarn.Api.Records.Resource GetReservationQueueResourceIfExists
            (Plan plan, ReservationId reservationId)
        {
            CSQueue resQueue = cs.GetQueue(reservationId.ToString());

            Org.Apache.Hadoop.Yarn.Api.Records.Resource reservationResource = null;
            if (resQueue != null)
            {
                reservationResource = Resources.Multiply(cs.GetClusterResource(), resQueue.GetAbsoluteCapacity
                                                             ());
            }
            return(reservationResource);
        }