forked from apache/flink
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Taskmanagers are now displayed in the web interface @rmetzger Author: Jonathan <[email protected]> Closes apache#43 from JonathanH5/webclient and squashes the following commits: 5cc5f72 [Jonathan] Finished Flink-928 and simplified how new pages to the WebInterface are added
- Loading branch information
Showing
18 changed files
with
505 additions
and
139 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
stratosphere-runtime/resources/web-docs-infoserver/js/taskmanager.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
|
||
$(document).ready(function() { | ||
pollTaskmanagers(); | ||
|
||
}); | ||
|
||
/* | ||
* Initializes taskmanagers table | ||
*/ | ||
function loadTaskmanagers(json) { | ||
$("#taskmanagerTable").empty(); | ||
var table = "<table class=\"table table-bordered table-hover table-striped\">"; | ||
table += "<tr><th>Node</th><th>Ipc Port</th><th>Data Port</th><th>Seconds since last Heartbeat</th>" + | ||
"<th>Number of Slots</th><th>Available Slots</th><th>CPU Cores</th><th>Physical Memory (mb)</th><th>TaskManager Heapsize (mb)</th></tr>"; | ||
for (var i = 0; i < json.taskmanagers.length; i++) { | ||
var tm = json.taskmanagers[i] | ||
table += "<tr><td>"+tm.inetAdress+"</td><td>"+tm.ipcPort+"</td><td>"+tm.dataPort+"</td><td>"+tm.timeSinceLastHeartbeat+"</td>" + | ||
"<td>"+tm.slotsNumber+"</td><td>"+tm.freeSlots+"</td><td>"+tm.cpuCores+"</td><td>"+tm.physicalMemory+"</td><td>"+tm.freeMemory+"</td></tr>"; | ||
} | ||
table += "</table>"; | ||
$("#taskmanagerTable").append(table); | ||
} | ||
|
||
function pollTaskmanagers() { | ||
$.ajax({ url : "setupInfo?get=taskmanagers", type : "GET", cache: false, success : function(json) { | ||
loadTaskmanagers(json); | ||
}, dataType : "json", | ||
}); | ||
setTimeout(function() { | ||
pollTaskmanagers(); | ||
}, 10000); | ||
} |
Oops, something went wrong.