mirror of https://gitee.com/bigwinds/arangodb
Merge branch 'devel' of https://github.com/arangodb/arangodb into devel
This commit is contained in:
commit
c091031ec7
|
@ -21,7 +21,8 @@
|
|||
/// @author Andreas Streichardt
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#pragma once
|
||||
#ifndef ARANGOD_CLUSTER_AGENCY_CALLBACK_H
|
||||
#define ARANGOD_CLUSTER_AGENCY_CALLBACK_H 1
|
||||
|
||||
#include <functional>
|
||||
#include <memory>
|
||||
|
@ -66,3 +67,6 @@ private:
|
|||
};
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
|
|
@ -21,7 +21,8 @@
|
|||
/// @author Andreas Streichardt
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#pragma once
|
||||
#ifndef ARANGOD_CLUSTER_AGENCY_CALLBACK_REGISTRY_H
|
||||
#define ARANGOD_CLUSTER_AGENCY_CALLBACK_REGISTRY_H 1
|
||||
|
||||
#include "Cluster/AgencyCallback.h"
|
||||
#include "Basics/ReadWriteLock.h"
|
||||
|
@ -73,3 +74,5 @@ private:
|
|||
};
|
||||
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -21,7 +21,8 @@
|
|||
/// @author Andreas Streichardt
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#pragma once
|
||||
#ifndef ARANGOD_CLUSTER_REST_AGENCY_CALLBACKS_HANDLER_H
|
||||
#define ARANGOD_CLUSTER_REST_AGENCY_CALLBACKS_HANDLER_H 1
|
||||
|
||||
#include "Basics/Common.h"
|
||||
#include "RestHandler/RestVocbaseBaseHandler.h"
|
||||
|
@ -52,3 +53,5 @@ class RestAgencyCallbacksHandler : public RestVocbaseBaseHandler {
|
|||
};
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -228,22 +228,23 @@
|
|||
var cssClass;
|
||||
|
||||
_.each(menuItems, function(menu, name) {
|
||||
cssClass = '';
|
||||
|
||||
if (menu.active) {
|
||||
cssClass += ' active';
|
||||
}
|
||||
if (menu.disabled) {
|
||||
cssClass += ' disabled';
|
||||
}
|
||||
|
||||
if (menu.disabled) {
|
||||
cssClass += ' disabled';
|
||||
}
|
||||
}
|
||||
else {
|
||||
cssClass = '';
|
||||
}
|
||||
$('#subNavigationBar .bottom').append(
|
||||
'<li class="subMenuEntry ' + cssClass + '"><a>' + name + '</a></li>'
|
||||
);
|
||||
$('#subNavigationBar .bottom').children().last().bind('click', function() {
|
||||
window.App.navigate(menu.route, {trigger: true});
|
||||
});
|
||||
if (!menu.disabled) {
|
||||
$('#subNavigationBar .bottom').children().last().bind('click', function() {
|
||||
window.App.navigate(menu.route, {trigger: true});
|
||||
});
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
|
|
|
@ -8,10 +8,12 @@
|
|||
|
||||
<% if (type !== 'coordinator') { %>
|
||||
<% disabled = " disabled"; %>
|
||||
<% } else { %>
|
||||
<% disabled = " "; %>
|
||||
<% } %>
|
||||
|
||||
<div class="pure-g cluster-nodes-title pure-table pure-table-header pure-title">
|
||||
<div class="pure-table-row <%= disabled %> ">
|
||||
<div class="pure-table-row">
|
||||
<div class="<%= genClass %> mid">Name</div>
|
||||
<div class="<%= genClass %> mid">Address</div>
|
||||
<div class="<%= genClass %> mid">Protocol</div>
|
||||
|
@ -29,7 +31,7 @@
|
|||
|
||||
<% _.each(coords, function(node) { %>
|
||||
|
||||
<div class="pure-table-row disabled" node="<%=node.name%>">
|
||||
<div class="pure-table-row <%= disabled %>" node="<%=node.name%>">
|
||||
|
||||
<div class="<%= genClass %> mid"><%= node.name %></div>
|
||||
<div class="<%= genClass %> mid"><%= node.address %></div>
|
||||
|
|
|
@ -300,6 +300,7 @@
|
|||
menuItem = menuItem.substr(1, menuItem.length - 1);
|
||||
}
|
||||
|
||||
//Location for selecting MainView Primary Navigaation Entry
|
||||
if (menuItem === '') {
|
||||
if (window.App.isCluster) {
|
||||
menuItem = 'cluster';
|
||||
|
@ -308,6 +309,9 @@
|
|||
menuItem = 'dashboard';
|
||||
}
|
||||
}
|
||||
else if (menuItem === 'cNodes' || menuItem === 'dNodes') {
|
||||
menuItem = 'nodes';
|
||||
}
|
||||
try {
|
||||
this.renderSubMenu(menuItem.split('-')[0]);
|
||||
}
|
||||
|
|
|
@ -417,7 +417,7 @@ function analyzeCoreDump(instanceInfo, options, storeArangodPath, pid) {
|
|||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
function analyzeCoreDumpWindows(instanceInfo) {
|
||||
const coreFN = instanceInfo.tmpDataDir + "\\" + "core.dmp";
|
||||
const coreFN = instanceInfo.rootDir + "\\" + "core.dmp";
|
||||
|
||||
if (!fs.exists(coreFN)) {
|
||||
print("core file " + coreFN + " not found?");
|
||||
|
@ -465,7 +465,7 @@ function checkArangoAlive(arangod, options) {
|
|||
const storeArangodPath = "/var/tmp/arangod_" + arangod.pid;
|
||||
|
||||
print("Core dump written; copying arangod to " +
|
||||
arangod.tmpDataDir + " for later analysis.");
|
||||
arangod.rootDir + " for later analysis.");
|
||||
|
||||
let corePath = (options.coreDirectory === "") ?
|
||||
"core" :
|
||||
|
|
|
@ -87,6 +87,11 @@ var findOrCreateCollectionByName = function (name, type, noCreate) {
|
|||
err.errorNum = arangodb.errors.ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION.code;
|
||||
err.errorMessage = name + arangodb.errors.ERROR_GRAPH_NOT_AN_ARANGO_COLLECTION.message;
|
||||
throw err;
|
||||
} else if (type === ArangoCollection.TYPE_EDGE && col.type() !== type) {
|
||||
var err2 = new ArangoError();
|
||||
err2.errorNum = arangodb.errors.ERROR_ARANGO_COLLECTION_TYPE_INVALID.code;
|
||||
err2.errorMessage = name + " cannot be used as relation. It is not an edge collection";
|
||||
throw err2;
|
||||
}
|
||||
return res;
|
||||
};
|
||||
|
|
|
@ -44,6 +44,7 @@ build/bin/arangod -c etc/relative/arangod.conf \
|
|||
--agency.wait-for-sync false \
|
||||
--database.directory cluster/data4001 \
|
||||
--agency.id 0 \
|
||||
--javascript.v8-contexts 1 \
|
||||
--log.file cluster/4001.log \
|
||||
--log.requests-file cluster/4001.req \
|
||||
--server.disable-statistics true \
|
||||
|
@ -248,12 +249,21 @@ if [ -n "$SECONDARIES" ]; then
|
|||
fi
|
||||
|
||||
echo Bootstrapping DBServers...
|
||||
curl -s -X POST "http://127.0.0.1:8530/_admin/cluster/bootstrapDbServers" \
|
||||
curl -s -f -X POST "http://127.0.0.1:8530/_admin/cluster/bootstrapDbServers" \
|
||||
-d '{"isRelaunch":false}' >> cluster/DBServersUpgrade.log 2>&1
|
||||
if [ "$?" != 0 ] ; then
|
||||
echo "Bootstrapping DBServers failed"
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
|
||||
echo Running DB upgrade on cluster...
|
||||
curl -s -X POST "http://127.0.0.1:8530/_admin/cluster/upgradeClusterDatabase" \
|
||||
curl -s -f -X POST "http://127.0.0.1:8530/_admin/cluster/upgradeClusterDatabase" \
|
||||
-d '{"isRelaunch":false}' >> cluster/DBUpgrade.log 2>&1
|
||||
if [ "$?" != 0 ] ; then
|
||||
echo "DB upgrade on cluster failed"
|
||||
exit 1;
|
||||
fi
|
||||
|
||||
echo Bootstrapping Coordinators...
|
||||
PIDS=""
|
||||
|
|
Loading…
Reference in New Issue