mirror of https://gitee.com/bigwinds/arangodb
Merge branch 'devel' of ssh://github.com/arangodb/ArangoDB into feature/minReplicationFactor
This commit is contained in:
commit
cef60902a6
|
@ -49,7 +49,7 @@ Removing without *force*:
|
|||
var analyzers = require("@arangodb/analyzers");
|
||||
var db = require("@arangodb").db;
|
||||
var analyzerName = "testAnalyzer";
|
||||
analyzers.save(analyzerName, "identity", "test properties");
|
||||
analyzers.save(analyzerName, "identity");
|
||||
|
||||
// removal
|
||||
var url = "/_api/analyzer/" + encodeURIComponent(analyzerName);
|
||||
|
@ -66,7 +66,7 @@ Removing with *force*:
|
|||
var analyzers = require("@arangodb/analyzers");
|
||||
var db = require("@arangodb").db;
|
||||
var analyzerName = "testAnalyzer";
|
||||
analyzers.save(analyzerName, "identity", "test properties");
|
||||
analyzers.save(analyzerName, "identity");
|
||||
|
||||
// create analyzer reference
|
||||
var url = "/_api/collection";
|
||||
|
|
|
@ -32,7 +32,7 @@ Retrieve an analyzer definition:
|
|||
var analyzers = require("@arangodb/analyzers");
|
||||
var db = require("@arangodb").db;
|
||||
var analyzerName = "testAnalyzer";
|
||||
analyzers.save(analyzerName, "identity", "test properties");
|
||||
analyzers.save(analyzerName, "identity");
|
||||
|
||||
// retrieval
|
||||
var url = "/_api/analyzer/" + encodeURIComponent(analyzerName);
|
||||
|
|
|
@ -166,6 +166,7 @@ void IndexNode::initIndexCoversProjections() {
|
|||
}
|
||||
|
||||
_coveringIndexAttributePositions = std::move(coveringAttributePositions);
|
||||
_options.forceProjection = true;
|
||||
}
|
||||
|
||||
/// @brief toVelocyPack, for IndexNode
|
||||
|
|
|
@ -199,6 +199,7 @@ function checkMonitorAlive (binary, arangod, options, res) {
|
|||
arangod.monitor.monitorExited = true;
|
||||
arangod.monitor.pid = null;
|
||||
pu.serverCrashed = true;
|
||||
options.cleanup = false;
|
||||
arangod['exitStatus'] = {};
|
||||
analyzeCrash(binary, arangod, options, "the process monitor commanded error");
|
||||
Object.assign(arangod.exitStatus,
|
||||
|
|
|
@ -948,7 +948,7 @@ bool StorageEngineMock::inRecoveryResult = false;
|
|||
StorageEngineMock::StorageEngineMock(arangodb::application_features::ApplicationServer& server)
|
||||
: StorageEngine(server, "Mock", "",
|
||||
std::unique_ptr<arangodb::IndexFactory>(new IndexFactoryMock())),
|
||||
_releasedTick(0) {
|
||||
vocbaseCount(0), _releasedTick(0){
|
||||
arangodb::FlushFeature::_defaultFlushSubscription =
|
||||
[](std::string const&, TRI_vocbase_t const&,
|
||||
arangodb::velocypack::Slice const&) -> arangodb::Result {
|
||||
|
|
|
@ -16,7 +16,7 @@ const base64Encode = require('internal').base64Encode;
|
|||
|
||||
function testSuite() {
|
||||
const jwtSecret = 'haxxmann';
|
||||
const user = 'hackers@arangodb.com';
|
||||
const user = 'bob';
|
||||
|
||||
const system = "_system";
|
||||
|
||||
|
@ -28,7 +28,8 @@ function testSuite() {
|
|||
|
||||
const name = "TestAuthAnalyzer";
|
||||
|
||||
users.save(user, ''); // password must be empty otherwise switchUser will not work
|
||||
if(!users.exists('bob'))
|
||||
users.save(user, ''); // password must be empty otherwise switchUser will not work
|
||||
|
||||
// analyzers can only be changed from the `_system` database
|
||||
// analyzer API does not support database selection via the usual `_db/<dbname>/_api/<api>`
|
||||
|
@ -50,11 +51,10 @@ function testSuite() {
|
|||
users.grantDatabase(user, system, "ro");
|
||||
users.grantDatabase(user, rodb, "ro");
|
||||
users.grantDatabase(user, rwdb, "rw");
|
||||
|
||||
users.grantCollection(user, system, "*", "none");
|
||||
users.grantCollection(user, rwdb, "*", "rw");
|
||||
users.grantCollection(user, rodb, "*", "ro");
|
||||
|
||||
|
||||
users.reload();
|
||||
},
|
||||
|
||||
|
|
|
@ -114,7 +114,8 @@ const waitForTaskStop = () => {
|
|||
|
||||
describe('User Rights Management', () => {
|
||||
before(() => {
|
||||
users.save('bob');
|
||||
if(!users.exists('bob'))
|
||||
users.save('bob');
|
||||
users.grantDatabase('bob', '_system', 'rw');
|
||||
users.grantCollection('bob', '_system', '*', 'rw');
|
||||
|
||||
|
|
Loading…
Reference in New Issue