1 | @model HeuristicLab.Services.Hive.Statistics.Models.OverallStatus
|
---|
2 |
|
---|
3 | @{
|
---|
4 | ViewBag.Title = "Status Monitor";
|
---|
5 | }
|
---|
6 |
|
---|
7 | <h1>Current Status</h1>
|
---|
8 |
|
---|
9 | <section>
|
---|
10 | <table>
|
---|
11 | <tr>
|
---|
12 | <td>Overall Available Cores</td>
|
---|
13 | <td>@Model.OverallCurrentlyAvailableCores</td>
|
---|
14 | </tr>
|
---|
15 | <tr>
|
---|
16 | <td>Availabe Cores (real)</td>
|
---|
17 | <td>@Model.CurrentlyAvailableCores</td>
|
---|
18 | </tr>
|
---|
19 | <tr>
|
---|
20 | <td>Used Cores</td>
|
---|
21 | <td>@Model.CurrentlyUsedCores</td>
|
---|
22 | </tr>
|
---|
23 | <tr>
|
---|
24 | <td>System-Wide Waiting Tasks</td>
|
---|
25 | <td>@Model.CurrentlyJobsWaiting</td>
|
---|
26 | </tr>
|
---|
27 | <tr>
|
---|
28 | <td>Overall Avg. CPU Utilization</td>
|
---|
29 | <td>@Model.OverallCpuUtilization</td>
|
---|
30 | </tr>
|
---|
31 | <tr>
|
---|
32 | <td>Available Avg. CPU Utilization</td>
|
---|
33 | <td>@Model.AvailableCpuUtilization</td>
|
---|
34 | </tr>
|
---|
35 | </table>
|
---|
36 | </section>
|
---|
37 |
|
---|
38 | <fieldset>
|
---|
39 | <legend>Range</legend>
|
---|
40 | <ol>
|
---|
41 | <li>Start</li>
|
---|
42 | <li>
|
---|
43 | @Html.TextBox("Start", (DateTime.Now - new TimeSpan(1, 0, 0, 0)).ToString("yyyy-MM-dd"), new { @class = "date" })
|
---|
44 | </li>
|
---|
45 | <li>End</li>
|
---|
46 | <li>
|
---|
47 | @Html.TextBox("End", DateTime.Now.ToString("yyyy-MM-dd"), new { @class = "date" })
|
---|
48 | </li>
|
---|
49 | </ol>
|
---|
50 | <button id="refresh">Refresh</button>
|
---|
51 | </fieldset>
|
---|
52 |
|
---|
53 | <section class="charts">
|
---|
54 | <div id="AverageCpuUtilization"></div>
|
---|
55 | <div id="UsedCores"></div>
|
---|
56 | <div id="UsedMemory"></div>
|
---|
57 | </section>
|
---|
58 |
|
---|
59 | @section Styles {
|
---|
60 | @Styles.Render("~/Styles/jqPlot/jquery.jqplot")
|
---|
61 | @Styles.Render("~/Content/themes/base/css")
|
---|
62 | }
|
---|
63 |
|
---|
64 | @section Scripts {
|
---|
65 | @Scripts.Render("~/bundles/jqueryui")
|
---|
66 | <script>
|
---|
67 | $("#refresh").button({
|
---|
68 | icons: {
|
---|
69 | primary: "ui-icon-refresh"
|
---|
70 | }
|
---|
71 | });
|
---|
72 | </script>
|
---|
73 |
|
---|
74 | @Scripts.Render("~/Scripts/jqPlot/jquery.jqplot")
|
---|
75 | @ChartHelper.AjaxDataRenderer()
|
---|
76 |
|
---|
77 | @ChartHelper.LineChartTime(
|
---|
78 | "AverageCpuUtilization",
|
---|
79 | Url.Action("AverageCpuUtilization", "ChartData"),
|
---|
80 | title: "Avg. CPU Utilization History of all Slaves",
|
---|
81 | axisYFormat: "%.2f%%",
|
---|
82 | minY: 0, maxY: 100)
|
---|
83 |
|
---|
84 | @ChartHelper.LineChartTime(
|
---|
85 | "UsedCores",
|
---|
86 | Url.Action("UsedCores", "ChartData"),
|
---|
87 | title: "Cores / Used Cores",
|
---|
88 | minY: 0)
|
---|
89 |
|
---|
90 | @ChartHelper.LineChartTime(
|
---|
91 | "UsedMemory",
|
---|
92 | Url.Action("UsedMemory", "ChartData"),
|
---|
93 | title: "Memory / Used Memory (GB)",
|
---|
94 | minY: 0)
|
---|
95 |
|
---|
96 | <script>
|
---|
97 | $(document).ready(function () {
|
---|
98 | $(".date").datepicker({
|
---|
99 | dateFormat: "yy-mm-dd",
|
---|
100 | onSelect: function () { refreshCharts(); }
|
---|
101 | });
|
---|
102 |
|
---|
103 | $("#refresh").click(function() {
|
---|
104 | refreshCharts();
|
---|
105 | });
|
---|
106 |
|
---|
107 |
|
---|
108 | });
|
---|
109 |
|
---|
110 | function refreshCharts() {
|
---|
111 | var startDate = $('#Start').val();
|
---|
112 | var endDate = $('#End').val();
|
---|
113 |
|
---|
114 | @*
|
---|
115 | var url = "@Url.Action("AverageCpuUtilization", "ChartData")?start=" + startDate + "&end" + endDate;
|
---|
116 |
|
---|
117 | @ChartHelper.LineChartTime(
|
---|
118 | "AverageCpuUtilization",
|
---|
119 | "url",
|
---|
120 | title: "Avg. CPU Utilization History of all Slaves",
|
---|
121 | axisYFormat: "%.2f%%",
|
---|
122 | minY: 0, maxY: 100)
|
---|
123 | *@
|
---|
124 |
|
---|
125 | @ChartHelper.RefreshChart("AverageCpuUtilization", Url.Action("AverageCpuUtilization", "ChartData"), "startDate", "endDate")
|
---|
126 | @ChartHelper.RefreshChart("UsedCores", Url.Action("UsedCores", "ChartData"), "startDate", "endDate")
|
---|
127 | @ChartHelper.RefreshChart("UsedMemory", Url.Action("UsedMemory", "ChartData"), "startDate", "endDate")
|
---|
128 | }
|
---|
129 | </script>
|
---|
130 | }
|
---|