コード例 #1
0
            protected override void Render(HtmlBlock.Block html)
            {
                ResponseInfo ri = Info("\'" + Sharpen.Runtime.Substring(lqinfo.GetQueuePath(), 5)
                                       + "\' Queue Status").("Queue State:", lqinfo.GetQueueState()).("Used Capacity:"
                                                                                                      , Percent(lqinfo.GetUsedCapacity() / 100)).("Absolute Used Capacity:", Percent(lqinfo
                                                                                                                                                                                     .GetAbsoluteUsedCapacity() / 100)).("Absolute Capacity:", Percent(lqinfo.GetAbsoluteCapacity
                                                                                                                                                                                                                                                           () / 100)).("Absolute Max Capacity:", Percent(lqinfo.GetAbsoluteMaxCapacity() /
                                                                                                                                                                                                                                                                                                         100)).("Used Resources:", lqinfo.GetResourcesUsed().ToString()).("Num Schedulable Applications:"
                                                                                                                                                                                                                                                                                                                                                                          , Sharpen.Extensions.ToString(lqinfo.GetNumActiveApplications())).("Num Non-Schedulable Applications:"
                                                                                                                                                                                                                                                                                                                                                                                                                                             , Sharpen.Extensions.ToString(lqinfo.GetNumPendingApplications())).("Num Containers:"
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 , Sharpen.Extensions.ToString(lqinfo.GetNumContainers())).("Max Applications:",
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            Sharpen.Extensions.ToString(lqinfo.GetMaxApplications())).("Max Applications Per User:"******"Max Application Master Resources:"
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           , lqinfo.GetAMResourceLimit().ToString()).("Used Application Master Resources:",
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      lqinfo.GetUsedAMResource().ToString()).("Max Application Master Resources Per User:"******"Configured Capacity:", Percent(lqinfo
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             .GetCapacity() / 100)).("Configured Max Capacity:", Percent(lqinfo.GetMaxCapacity
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             () / 100)).("Configured Minimum User Limit Percent:", Sharpen.Extensions.ToString
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             (lqinfo.GetUserLimit()) + "%").("Configured User Limit Factor:", string.Format("%.1f"
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            , lqinfo.GetUserLimitFactor())).("Accessible Node Labels:", StringUtils.Join(","
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         , lqinfo.GetNodeLabels())).("Preemption:", lqinfo.GetPreemptionDisabled() ? "disabled"
                                         : "enabled");

                html.(typeof(InfoBlock));
                // clear the info contents so this queue's info doesn't accumulate into another queue's info
                ri.Clear();
            }
コード例 #2
0
            protected override void Render(HtmlBlock.Block html)
            {
                ResponseInfo ri = Info("\'" + qinfo.GetQueueName() + "\' Queue Status").("Used Resources:"
                                                                                         , qinfo.GetUsedResources().ToString()).("Num Active Applications:", qinfo.GetNumActiveApplications
                                                                                                                                     ()).("Num Pending Applications:", qinfo.GetNumPendingApplications()).("Min Resources:"
                                                                                                                                                                                                           , qinfo.GetMinResources().ToString()).("Max Resources:", qinfo.GetMaxResources()
                                                                                                                                                                                                                                                  .ToString());
                int maxApps = qinfo.GetMaxApplications();

                if (maxApps < int.MaxValue)
                {
                    ri.("Max Running Applications:", qinfo.GetMaxApplications());
                }
                ri.(SteadyFairShare + ":", qinfo.GetSteadyFairShare().ToString());
                ri.(InstantaneousFairShare + ":", qinfo.GetFairShare().ToString());
                html.(typeof(InfoBlock));
                // clear the info contents so this queue's info doesn't accumulate into another queue's info
                ri.Clear();
            }