mirror of https://gitee.com/bigwinds/arangodb
Merge branch 'devel' of https://github.com/arangodb/arangodb into devel
This commit is contained in:
commit
40934621c7
20
CHANGELOG
20
CHANGELOG
|
|
@ -257,8 +257,26 @@ v3.2.alpha1 (2017-02-05)
|
|||
|
||||
* generated Foxx services now use swagger tags
|
||||
|
||||
v3.1.20 (XXXX-XX-XX)
|
||||
--------------------
|
||||
|
||||
v3.1.19 (XXXX-XX-XX)
|
||||
* fixed incorrect sorting for distributeShardsLike
|
||||
|
||||
* improve reliability of AgencyComm communication with Agency
|
||||
|
||||
* fixed shard numbering bug, where ids were erouneously incremented by 1
|
||||
|
||||
* remove an unnecessary precondition in createCollectionCoordinator
|
||||
|
||||
* funny fail rotation fix
|
||||
|
||||
* fix in SimpleHttpClient for correct advancement of readBufferOffset
|
||||
|
||||
* forward SIG_HUP in supervisor process to the server process to fix logrotaion
|
||||
You need to stop the remaining arangod server process manually for the upgrade to work.
|
||||
|
||||
|
||||
v3.1.19 (2017-04-28)
|
||||
--------------------
|
||||
|
||||
* Fixed a StackOverflow issue in Traversal and ShortestPath. Occured if many (>1000) input
|
||||
|
|
|
|||
|
|
@ -486,6 +486,34 @@ actions.defineHttp({
|
|||
return;
|
||||
}
|
||||
|
||||
Health = Object.entries(Health).reduce((Health, [serverId,struct]) => {
|
||||
let canBeDeleted = false;
|
||||
if (struct.Role === 'Coordinator') {
|
||||
canBeDeleted = struct.Status === 'FAILED';
|
||||
} else if (struct.Role === 'DBServer') {
|
||||
if (struct.Status === 'FAILED') {
|
||||
let numUsed = reducePlanServers(function(numUsed, agencyKey, servers) {
|
||||
if (servers.indexOf(serverId) !== -1) {
|
||||
numUsed++;
|
||||
}
|
||||
return numUsed;
|
||||
}, 0);
|
||||
if (numUsed === 0) {
|
||||
numUsed = reduceCurrentServers(function(numUsed, agencyKey, servers) {
|
||||
if (servers.indexOf(serverId) !== -1) {
|
||||
numUsed++;
|
||||
}
|
||||
return numUsed;
|
||||
}, 0);
|
||||
}
|
||||
canBeDeleted = numUsed === 0;
|
||||
}
|
||||
}
|
||||
// the structure is all uppercase for whatever reason so make it uppercase as well
|
||||
Health[serverId].CanBeDeleted = canBeDeleted;
|
||||
return Health;
|
||||
}, Health);
|
||||
|
||||
actions.resultOk(req, res, actions.HTTP_OK, {Health});
|
||||
}
|
||||
});
|
||||
|
|
|
|||
File diff suppressed because one or more lines are too long
Binary file not shown.
Binary file not shown.
|
|
@ -2170,7 +2170,7 @@ if (list.length > 0) {
|
|||
|
||||
<div class="pure-g cluster-nodes coords-nodes pure-table pure-table-body"> <% _.each(coords, function(node, name) { %> <% var id = name + "-node"; %> <div class="pure-table-row <%= disabled %>" node="<%= id %>">
|
||||
|
||||
<div class="pure-u-10-24 left"> <%= node.ShortName %> <i class="fa fa-bar-chart"></i> <% if(node.Status === 'FAILED') { %> <i class="fa fa-trash-o"></i> <% } %> </div>
|
||||
<div class="pure-u-10-24 left"> <%= node.ShortName %> <i class="fa fa-bar-chart"></i> <% if(node.CanBeDeleted) { %> <i class="fa fa-trash-o"></i> <% } %> </div>
|
||||
<div class="pure-u-10-24 left"><%= node.Endpoint %></div> <% var formatted = (node.LastHeartbeatAcked).substr(11, 18).slice(0, -1); %> <div class="pure-u-3-24 hide-small mid"><%= formatted %></div> <% if(node.Status === 'GOOD') { %> <div class="pure-u-1-24 mid state"><i class="fa fa-check-circle tippy" title="<%= node.LastHeartbeatStatus %>"></i></div> <% } else { %> <div class="pure-u-1-24 mid state"><i class="fa fa-exclamation-circle"></i></div> <% } %> </div> <% }); %> </div>
|
||||
</div> <% } %> <% if (Object.keys(dbs).length > 0) { %> <% var disabled = ''; %> <% disabled = " dbserver"; %> <div class="pure-u-1-1 pure-u-md-1-1 pure-u-lg-1-1 pure-u-xl-1-2">
|
||||
<div class="sectionHeader pure-g">
|
||||
|
|
@ -2203,7 +2203,7 @@ if (list.length > 0) {
|
|||
</div>
|
||||
</div> <% } %> <div class="pure-g cluster-nodes dbs-nodes pure-table pure-table-body"> <% _.each(dbs, function(node, name) { %> <% var id = name + "-node"; %> <div class="pure-table-row <%= disabled %>" node="<%= id %>">
|
||||
|
||||
<div class="pure-u-10-24 left"><%= node.ShortName %></div>
|
||||
<div class="pure-u-10-24 left"> <%= node.ShortName %> <% if(node.CanBeDeleted) { %> <i class="fa fa-trash-o"></i> <% } %> </div>
|
||||
<div class="pure-u-10-24 left"><%= node.Endpoint %></div> <% var formatted = (node.LastHeartbeatAcked).substr(11, 18).slice(0, -1); %> <div class="pure-u-3-24 mid hide-small"><%= formatted %></div> <% if(node.Status === 'GOOD') { %> <div class="pure-u-1-24 mid state"><i class="fa fa-check-circle tippy" title="<%= node.LastHeartbeatStatus %>"></i></div> <% } else { %> <div class="pure-u-1-24 mid state"><i class="fa fa-exclamation-circle"></i></div> <% } %> </div> <% }); %> </div>
|
||||
</div>
|
||||
|
||||
|
|
@ -2779,4 +2779,4 @@ var cutByResolution = function (str) {
|
|||
</div>
|
||||
|
||||
<div id="workMonitorContent" class="innerContent">
|
||||
</div></script></head><body><nav class="navbar" style="display: none"><div class="primary"><div class="navlogo"><a class="logo big" href="#"><img id="ArangoDBLogo" class="arangodbLogo" src="img/arangodb-edition-optimized.svg"></a><a class="logo small" href="#"><img class="arangodbLogo" src="img/arangodb_logo_small.png"></a><a class="version"><span id="currentVersion"></span></a></div><div class="statmenu" id="statisticBar"></div><div class="navmenu" id="navigationBar"></div></div></nav><div id="modalPlaceholder"></div><div class="bodyWrapper" style="display: none"><div class="centralRow"><div id="navbar2" class="navbarWrapper secondary"><div class="subnavmenu" id="subNavigationBar"></div></div><div class="resizecontainer contentWrapper"><div id="loadingScreen" class="loadingScreen" style="display: none"><i class="fa fa-circle-o-notch fa-spin fa-3x fa-fw margin-bottom"></i> <span class="sr-only">Loading...</span></div><div id="content" class="centralContent"></div><footer class="footer"><div id="footerBar"></div></footer></div></div></div><div id="progressPlaceholder" style="display:none"></div><div id="spotlightPlaceholder" style="display:none"></div><div id="graphSettingsContent" style="display: none"></div><div id="filterSelectDiv" style="display:none"></div><div id="offlinePlaceholder" style="display:none"><div class="offline-div"><div class="pure-u"><div class="pure-u-1-4"></div><div class="pure-u-1-2 offline-window"><div class="offline-header"><h3>You have been disconnected from the server</h3></div><div class="offline-body"><p>The connection to the server has been lost. The server may be under heavy load.</p><p>Trying to reconnect in <span id="offlineSeconds">10</span> seconds.</p><p class="animation_state"><span><button class="button-success">Reconnect now</button></span></p></div></div><div class="pure-u-1-4"></div></div></div></div><div class="arangoFrame" style=""><div class="outerDiv"><div class="innerDiv"></div></div></div><script src="libs.js?version=1494419319160"></script><script src="app.js?version=1494419319160"></script></body></html>
|
||||
</div></script></head><body><nav class="navbar" style="display: none"><div class="primary"><div class="navlogo"><a class="logo big" href="#"><img id="ArangoDBLogo" class="arangodbLogo" src="img/arangodb-edition-optimized.svg"></a><a class="logo small" href="#"><img class="arangodbLogo" src="img/arangodb_logo_small.png"></a><a class="version"><span id="currentVersion"></span></a></div><div class="statmenu" id="statisticBar"></div><div class="navmenu" id="navigationBar"></div></div></nav><div id="modalPlaceholder"></div><div class="bodyWrapper" style="display: none"><div class="centralRow"><div id="navbar2" class="navbarWrapper secondary"><div class="subnavmenu" id="subNavigationBar"></div></div><div class="resizecontainer contentWrapper"><div id="loadingScreen" class="loadingScreen" style="display: none"><i class="fa fa-circle-o-notch fa-spin fa-3x fa-fw margin-bottom"></i> <span class="sr-only">Loading...</span></div><div id="content" class="centralContent"></div><footer class="footer"><div id="footerBar"></div></footer></div></div></div><div id="progressPlaceholder" style="display:none"></div><div id="spotlightPlaceholder" style="display:none"></div><div id="graphSettingsContent" style="display: none"></div><div id="filterSelectDiv" style="display:none"></div><div id="offlinePlaceholder" style="display:none"><div class="offline-div"><div class="pure-u"><div class="pure-u-1-4"></div><div class="pure-u-1-2 offline-window"><div class="offline-header"><h3>You have been disconnected from the server</h3></div><div class="offline-body"><p>The connection to the server has been lost. The server may be under heavy load.</p><p>Trying to reconnect in <span id="offlineSeconds">10</span> seconds.</p><p class="animation_state"><span><button class="button-success">Reconnect now</button></span></p></div></div><div class="pure-u-1-4"></div></div></div></div><div class="arangoFrame" style=""><div class="outerDiv"><div class="innerDiv"></div></div></div><script src="libs.js?version=1494508672940"></script><script src="app.js?version=1494508672940"></script></body></html>
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
|
|
@ -62,7 +62,7 @@
|
|||
<div class="pure-u-10-24 left">
|
||||
<%= node.ShortName %>
|
||||
<i class="fa fa-bar-chart"></i>
|
||||
<% if(node.Status === 'FAILED') { %>
|
||||
<% if(node.CanBeDeleted) { %>
|
||||
<i class="fa fa-trash-o"></i>
|
||||
<% } %>
|
||||
</div>
|
||||
|
|
@ -139,7 +139,12 @@
|
|||
|
||||
<div class="pure-table-row <%= disabled %>" node="<%= id %>">
|
||||
|
||||
<div class="pure-u-10-24 left"><%= node.ShortName %></div>
|
||||
<div class="pure-u-10-24 left">
|
||||
<%= node.ShortName %>
|
||||
<% if(node.CanBeDeleted) { %>
|
||||
<i class="fa fa-trash-o"></i>
|
||||
<% } %>
|
||||
</div>
|
||||
<div class="pure-u-10-24 left"><%= node.Endpoint %></div>
|
||||
|
||||
<% var formatted = (node.LastHeartbeatAcked).substr(11, 18).slice(0, -1); %>
|
||||
|
|
|
|||
|
|
@ -14,6 +14,7 @@
|
|||
'click #nodesContent .coords-nodes .pure-table-row': 'navigateToNode',
|
||||
'click #nodesContent .dbs-nodes .pure-table-row': 'navigateToNode',
|
||||
'click #nodesContent .coords-nodes .pure-table-row .fa-trash-o': 'deleteNode',
|
||||
'click #nodesContent .dbs-nodes .pure-table-row .fa-trash-o': 'deleteNode',
|
||||
'click #addCoord': 'addCoord',
|
||||
'click #removeCoord': 'removeCoord',
|
||||
'click #addDBs': 'addDBs',
|
||||
|
|
|
|||
Binary file not shown.
Binary file not shown.
|
|
@ -104,6 +104,14 @@ static void StopHandler(int) {
|
|||
|
||||
}
|
||||
|
||||
static void HUPHandler(int) {
|
||||
LOG_TOPIC(INFO, Logger::STARTUP) << "received SIGHUP for supervisor; commanding client [" << CLIENT_PID << "] to logrotate.";
|
||||
int rc = kill(CLIENT_PID, SIGHUP);
|
||||
if (rc < 0) {
|
||||
LOG_TOPIC(ERR, Logger::STARTUP) << "commanding client [" << CLIENT_PID << "] to logrotate failed: [" << errno << "] " << strerror(errno);
|
||||
}
|
||||
}
|
||||
|
||||
SupervisorFeature::SupervisorFeature(
|
||||
application_features::ApplicationServer* server)
|
||||
: ApplicationFeature(server, "Supervisor"), _supervisor(false), _clientPid(0) {
|
||||
|
|
@ -189,6 +197,7 @@ void SupervisorFeature::daemonize() {
|
|||
if (0 < _clientPid) {
|
||||
signal(SIGINT, StopHandler);
|
||||
signal(SIGTERM, StopHandler);
|
||||
signal(SIGHUP, HUPHandler);
|
||||
|
||||
LOG_TOPIC(INFO, Logger::STARTUP) << "supervisor has forked a child process with pid " << _clientPid;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue