Skip to content

Commit

Permalink
audit-recovery more detailed
Browse files Browse the repository at this point in the history
  • Loading branch information
shlomi-noach committed Oct 27, 2015
1 parent f482d3b commit be454ff
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
#
set -e

RELEASE_VERSION="1.4.469"
RELEASE_VERSION="1.4.470"
TOPDIR=/tmp/orchestrator-release
export RELEASE_VERSION TOPDIR

Expand Down
16 changes: 12 additions & 4 deletions resources/public/js/audit-recovery.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ $(document).ready(function () {
var ack = $('<span class="pull-left glyphicon acknowledge-indicator" title=""></span>');
if (audit.Acknowledged) {
ack.addClass("glyphicon-ok-sign").addClass("text-primary");
ack.attr("title", "Acknowledged by "+audit.AcknowledgedBy+" at "+audit.AcknowledgedAt+": "+audit.AcknowledgedComment);
var ackTitle = "Acknowledged by "+audit.AcknowledgedBy+" at "+audit.AcknowledgedAt+": "+audit.AcknowledgedComment;
ack.attr("title", ackTitle);
} else {
ack.addClass("glyphicon-question-sign").addClass("text-danger").addClass("unacknowledged");
ack.attr("data-recovery-id", audit.Id);
Expand All @@ -43,24 +44,31 @@ $(document).ready(function () {
$('<td/>', { text: "pending" }).appendTo(row);
}
var moreInfo = "";
if (audit.Acknowledged) {
moreInfo += '<div>Acknowledged by '+audit.AcknowledgedBy+', '+audit.AcknowledgedAt+'<ul>';
moreInfo += "<li>"+audit.AcknowledgedComment+"</li>";
moreInfo += '</ul></div>';
} else {
moreInfo += '<div><strong>Unacknowledged</strong></div>';
}
if (audit.LostSlaves.length > 0) {
moreInfo += "<div>Lost slaves:<ul>";
audit.LostSlaves.forEach(function(instanceKey) {
moreInfo += "<li><code>"+getInstanceTitle(instanceKey.Hostname, instanceKey.Port)+"</code>";
moreInfo += "<li><code>"+getInstanceTitle(instanceKey.Hostname, instanceKey.Port)+"</code></li>";
});
moreInfo += "</ul></div>";
}
if (audit.ParticipatingInstanceKeys.length > 0) {
moreInfo += "<div>Participating instances:<ul>";
audit.ParticipatingInstanceKeys.forEach(function(instanceKey) {
moreInfo += "<li><code>"+getInstanceTitle(instanceKey.Hostname, instanceKey.Port)+"</code>";
moreInfo += "<li><code>"+getInstanceTitle(instanceKey.Hostname, instanceKey.Port)+"</code></li>";
});
moreInfo += "</ul></div>";
}
if (audit.AnalysisEntry.SlaveHosts.length > 0) {
moreInfo += '<div>'+audit.AnalysisEntry.CountSlaves+' slave hosts :<ul>';
audit.AnalysisEntry.SlaveHosts.forEach(function(instanceKey) {
moreInfo += "<li><code>"+getInstanceTitle(instanceKey.Hostname, instanceKey.Port)+"</code>";
moreInfo += "<li><code>"+getInstanceTitle(instanceKey.Hostname, instanceKey.Port)+"</code></li>";
});
moreInfo += "</ul></div>";
}
Expand Down

0 comments on commit be454ff

Please sign in to comment.