mirror of https://gitee.com/bigwinds/arangodb
fixed web interface in non-cluster mode
This commit is contained in:
parent
5a585db592
commit
cb5af05a76
|
@ -35,8 +35,13 @@
|
|||
// Initialise a new FoxxController called controller under the urlPrefix: "cluster".
|
||||
var FoxxController = require("org/arangodb/foxx").Controller,
|
||||
controller = new FoxxController(applicationContext),
|
||||
_ = require("underscore"),
|
||||
Communication = require("org/arangodb/sharding/agency-communication"),
|
||||
cluster = require("org/arangodb/cluster"),
|
||||
_ = require("underscore");
|
||||
|
||||
if (cluster.isCluster()) {
|
||||
// only make these functions available in cluster mode!
|
||||
|
||||
var Communication = require("org/arangodb/sharding/agency-communication"),
|
||||
comm = new Communication.Communication(),
|
||||
beats = comm.sync.Heartbeats(),
|
||||
servers = comm.current.DBServers(),
|
||||
|
@ -118,4 +123,6 @@
|
|||
);
|
||||
});
|
||||
|
||||
} // end isCluster()
|
||||
|
||||
}());
|
||||
|
|
Loading…
Reference in New Issue