1
0
Fork 0

Start documentation for sharding.

This commit is contained in:
Max Neunhoeffer 2014-02-07 16:08:28 +01:00
parent 6c4a9d45d7
commit fe25b3a1d1
6 changed files with 57 additions and 2 deletions

View File

@ -181,6 +181,9 @@ DOXYGEN = \
Doxygen/js/server/modules/org/arangodb/foxx/template_middleware.c \
Doxygen/js/server/modules/org/arangodb/graph.c \
Doxygen/js/server/modules/org/arangodb/simple-query.c \
Doxygen/js/server/modules/org/arangodb/cluster.c \
Doxygen/js/server/modules/org/arangodb/cluster/planner.c \
Doxygen/js/server/modules/org/arangodb/cluster/kickstarter.c \
Doxygen/js/server/server.c
## -----------------------------------------------------------------------------
@ -202,6 +205,7 @@ doxygen-create-directories:
@test -d Doxygen/js/common/modules/org/arangodb/graph || mkdir -p Doxygen/js/common/modules/org/arangodb/graph
@test -d Doxygen/js/server/modules/org/arangodb/foxx || mkdir -p Doxygen/js/server/modules/org/arangodb/foxx
@test -d Doxygen/js/server/modules/org/arangodb/graph || mkdir -p Doxygen/js/server/modules/org/arangodb/graph
@test -d Doxygen/js/server/modules/org/arangodb/cluster || mkdir -p Doxygen/js/server/modules/org/arangodb/cluster
@test -d Doxygen/js/client || mkdir -p Doxygen/js/client
@test -d Doxygen/man/man1 || mkdir -p Doxygen/man/man1
@test -d Doxygen/man/man8 || mkdir -p Doxygen/man/man8

View File

@ -8,6 +8,7 @@ ArangoDB's Reference Manual (@VERSION) {#RefManual}
@CHAPTER_REF{JSModuleFs}
@CHAPTER_REF{JSModuleGraph}
@CHAPTER_REF{JSModuleActions}
@CHAPTER_REF{JSModuleCluster}
@CHAPTER_REF{jsUnity}
@CHAPTER_REF{UserManualActions}
@CHAPTER_REF{RefManualReplication}

View File

@ -147,4 +147,7 @@ currently using. We will probably see a speedup in a later release.
The basic CRUD operations already have a relatively good performance,
the simple queries are in need of further optimisations as well.
See @ref JSModuleCluster "the corresponding chapter of the reference manual"
for detailed information about the `Planner` and `Kickstarter` classes.
@NAVIGATE_Sharding

View File

@ -32,6 +32,8 @@ var console = require("console");
var arangodb = require("org/arangodb");
var ArangoCollection = arangodb.ArangoCollection;
var ArangoError = arangodb.ArangoError;
var Planner = require("org/arangodb/cluster/planner").Planner;
var Kickstarter = require("org/arangodb/cluster/kickstarter").Kickstarter;
////////////////////////////////////////////////////////////////////////////////
/// @brief get values from Plan or Current by a prefix
@ -829,6 +831,9 @@ exports.status = status;
exports.isCoordinatorRequest = isCoordinatorRequest;
exports.handlePlanChange = handlePlanChange;
exports.Planner = Planner;
exports.Kickstarter = Kickstarter;
// -----------------------------------------------------------------------------
// --SECTION-- END-OF-FILE
// -----------------------------------------------------------------------------

View File

@ -4,7 +4,7 @@
////////////////////////////////////////////////////////////////////////////////
/// @brief Cluster kickstarting functionality using dispatchers
///
/// @file js/server/modules/org/arangodb/cluster/kickstarter.js
/// @file
///
/// DISCLAIMER
///

View File

@ -4,7 +4,7 @@
////////////////////////////////////////////////////////////////////////////////
/// @brief Cluster planning functionality
///
/// @file js/server/modules/org/arangodb/cluster/planner.js
/// @file
///
/// DISCLAIMER
///
@ -238,6 +238,48 @@ function fillConfigWithDefaults (config, defaultConfig) {
}
// Our Planner class:
////////////////////////////////////////////////////////////////////////////////
/// @fn JSF_Cluster_Planner_Constructor
/// @brief the cluster planner constructor
///
/// @FUN{new Planner(@FA{userConfig})}
///
/// This constructor builds a cluster planner object. The one and only
/// argument is an object that can have the following properties:
///
/// - `numberOfAgents`: the number of agents in the agency,
/// usually there is no reason to deviate from the default of 3
/// - `numberOfDBservers`: the number of DBservers in the
/// cluster.
/// - `numberOfCoordinators`: the number of coordinators in the cluster.
///
/// All these values have default values. Here is the current set of
/// default values:
///
/// {
/// "agencyPrefix" : "meier",
/// "numberOfAgents" : 3,
/// "numberOfDBservers" : 2,
/// "startSecondaries" : false,
/// "numberOfCoordinators" : 1,
/// "DBserverIDs" : ["Pavel", "Perry", "Pancho", "Paul",
/// "Pierre", "Pit", "Pia", "Pablo" ],
/// "coordinatorIDs" : ["Claus", "Chantalle", "Claire",
/// "Claudia", "Claas", "Clemens", "Chris" ],
/// "dataPath" : "",
/// "logPath" : "",
/// "arangodPath" : "bin/arangod",
/// "agentPath" : "bin/etcd",
/// "agentExtPorts" : [4001],
/// "agentIntPorts" : [7001],
/// "DBserverPorts" : [8629],
/// "coordinatorPorts" : [8530],
/// "dispatchers" : {"me":{"id":"me",
/// "endpoint":"tcp://localhost:",
/// "avoidPorts": {}}}
/// };
///
////////////////////////////////////////////////////////////////////////////////
function Planner (userConfig) {
"use strict";