mirror of https://gitee.com/bigwinds/arangodb
fix Windows build
This commit is contained in:
parent
0c00738aff
commit
3a582af765
|
@ -34,6 +34,7 @@
|
||||||
#include <velocypack/Slice.h>
|
#include <velocypack/Slice.h>
|
||||||
#include <velocypack/velocypack-aliases.h>
|
#include <velocypack/velocypack-aliases.h>
|
||||||
|
|
||||||
|
using namespace arangodb;
|
||||||
using namespace arangodb::aql;
|
using namespace arangodb::aql;
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
|
@ -30,6 +30,7 @@
|
||||||
#include "Basics/Exceptions.h"
|
#include "Basics/Exceptions.h"
|
||||||
#include "Basics/json.h"
|
#include "Basics/json.h"
|
||||||
#include "Basics/JsonHelper.h"
|
#include "Basics/JsonHelper.h"
|
||||||
|
#include "utils/Transaction.h"
|
||||||
|
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
// turn off warnings about too long type name for debug symbols blabla in MSVC
|
// turn off warnings about too long type name for debug symbols blabla in MSVC
|
||||||
|
@ -37,6 +38,7 @@
|
||||||
#pragma warning(disable : 4503)
|
#pragma warning(disable : 4503)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
using namespace arangodb;
|
||||||
using namespace arangodb::aql;
|
using namespace arangodb::aql;
|
||||||
using CompareResult = ConditionPartCompareResult;
|
using CompareResult = ConditionPartCompareResult;
|
||||||
|
|
||||||
|
@ -362,7 +364,7 @@ void Condition::andCombine(AstNode const* node) {
|
||||||
|
|
||||||
std::pair<bool, bool> Condition::findIndexes(
|
std::pair<bool, bool> Condition::findIndexes(
|
||||||
EnumerateCollectionNode const* node,
|
EnumerateCollectionNode const* node,
|
||||||
std::vector<Transaction::IndexHandle>& usedIndexes,
|
std::vector<arangodb::Transaction::IndexHandle>& usedIndexes,
|
||||||
SortCondition const* sortCondition) {
|
SortCondition const* sortCondition) {
|
||||||
TRI_ASSERT(usedIndexes.empty());
|
TRI_ASSERT(usedIndexes.empty());
|
||||||
Variable const* reference = node->outVariable();
|
Variable const* reference = node->outVariable();
|
||||||
|
|
|
@ -677,7 +677,7 @@ static void GetDocumentByIdentifier(arangodb::AqlTransaction* trx,
|
||||||
try {
|
try {
|
||||||
TRI_voc_cid_t cid;
|
TRI_voc_cid_t cid;
|
||||||
RegisterCollectionInTransaction(trx, collectionName, cid);
|
RegisterCollectionInTransaction(trx, collectionName, cid);
|
||||||
} catch (arangodb::basics::Exception const& ex) {
|
} catch (arangodb::basics::Exception const&) {
|
||||||
if (ignoreError) {
|
if (ignoreError) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -693,7 +693,7 @@ static void GetDocumentByIdentifier(arangodb::AqlTransaction* trx,
|
||||||
try {
|
try {
|
||||||
TRI_voc_cid_t cid;
|
TRI_voc_cid_t cid;
|
||||||
RegisterCollectionInTransaction(trx, parts[0], cid);
|
RegisterCollectionInTransaction(trx, parts[0], cid);
|
||||||
} catch (arangodb::basics::Exception const& ex) {
|
} catch (arangodb::basics::Exception const&) {
|
||||||
if (ignoreError) {
|
if (ignoreError) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -714,7 +714,7 @@ static void GetDocumentByIdentifier(arangodb::AqlTransaction* trx,
|
||||||
try {
|
try {
|
||||||
TRI_voc_cid_t cid;
|
TRI_voc_cid_t cid;
|
||||||
RegisterCollectionInTransaction(trx, collectionName, cid);
|
RegisterCollectionInTransaction(trx, collectionName, cid);
|
||||||
} catch (arangodb::basics::Exception const& ex) {
|
} catch (arangodb::basics::Exception const&) {
|
||||||
if (ignoreError) {
|
if (ignoreError) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,6 +28,7 @@
|
||||||
#include "Aql/ExecutionPlan.h"
|
#include "Aql/ExecutionPlan.h"
|
||||||
#include "Utils/Transaction.h"
|
#include "Utils/Transaction.h"
|
||||||
|
|
||||||
|
using namespace arangodb;
|
||||||
using namespace arangodb::aql;
|
using namespace arangodb::aql;
|
||||||
|
|
||||||
using JsonHelper = arangodb::basics::JsonHelper;
|
using JsonHelper = arangodb::basics::JsonHelper;
|
||||||
|
@ -38,7 +39,7 @@ using JsonHelper = arangodb::basics::JsonHelper;
|
||||||
|
|
||||||
IndexNode::IndexNode(ExecutionPlan* plan, size_t id, TRI_vocbase_t* vocbase,
|
IndexNode::IndexNode(ExecutionPlan* plan, size_t id, TRI_vocbase_t* vocbase,
|
||||||
Collection const* collection, Variable const* outVariable,
|
Collection const* collection, Variable const* outVariable,
|
||||||
std::vector<Transaction::IndexHandle> const& indexes,
|
std::vector<arangodb::Transaction::IndexHandle> const& indexes,
|
||||||
Condition* condition, bool reverse)
|
Condition* condition, bool reverse)
|
||||||
: ExecutionNode(plan, id),
|
: ExecutionNode(plan, id),
|
||||||
_vocbase(vocbase),
|
_vocbase(vocbase),
|
||||||
|
|
|
@ -24,6 +24,8 @@
|
||||||
#include "ClusterTraverser.h"
|
#include "ClusterTraverser.h"
|
||||||
#include "Cluster/ClusterMethods.h"
|
#include "Cluster/ClusterMethods.h"
|
||||||
|
|
||||||
|
using namespace arangodb;
|
||||||
|
|
||||||
using ClusterTraversalPath = arangodb::traverser::ClusterTraversalPath;
|
using ClusterTraversalPath = arangodb::traverser::ClusterTraversalPath;
|
||||||
using ClusterTraverser = arangodb::traverser::ClusterTraverser;
|
using ClusterTraverser = arangodb::traverser::ClusterTraverser;
|
||||||
|
|
||||||
|
|
|
@ -105,7 +105,7 @@ static bool indexSupportsSort(Index const* idx, arangodb::aql::Variable const* r
|
||||||
static OperationResult DBServerResponseBad(std::shared_ptr<VPackBuilder> resultBody) {
|
static OperationResult DBServerResponseBad(std::shared_ptr<VPackBuilder> resultBody) {
|
||||||
VPackSlice res = resultBody->slice();
|
VPackSlice res = resultBody->slice();
|
||||||
return OperationResult(
|
return OperationResult(
|
||||||
arangodb::basics::VelocyPackHelper::getNumericValue<uint64_t>(
|
arangodb::basics::VelocyPackHelper::getNumericValue<int>(
|
||||||
res, "errorNum", TRI_ERROR_INTERNAL),
|
res, "errorNum", TRI_ERROR_INTERNAL),
|
||||||
arangodb::basics::VelocyPackHelper::getStringValue(
|
arangodb::basics::VelocyPackHelper::getStringValue(
|
||||||
res, "errorMessage", "JSON sent to DBserver was bad"));
|
res, "errorMessage", "JSON sent to DBserver was bad"));
|
||||||
|
|
|
@ -207,7 +207,7 @@ void BenchFeature::start() {
|
||||||
|
|
||||||
BenchmarkThread* thread = new BenchmarkThread(
|
BenchmarkThread* thread = new BenchmarkThread(
|
||||||
benchmark.get(), &startCondition, &BenchFeature::updateStartCounter,
|
benchmark.get(), &startCondition, &BenchFeature::updateStartCounter,
|
||||||
i, (unsigned long)_batchSize, &operationsCounter, client, _keepAlive,
|
static_cast<int>(i), (unsigned long)_batchSize, &operationsCounter, client, _keepAlive,
|
||||||
_async, _verbose);
|
_async, _verbose);
|
||||||
|
|
||||||
threads.push_back(thread);
|
threads.push_back(thread);
|
||||||
|
|
|
@ -147,7 +147,7 @@ void ShellFeature::start() {
|
||||||
try {
|
try {
|
||||||
switch (_runMode) {
|
switch (_runMode) {
|
||||||
case RunMode::INTERACTIVE:
|
case RunMode::INTERACTIVE:
|
||||||
ok = shell->runShell(_positionals);
|
ok = (shell->runShell(_positionals) == TRI_ERROR_NO_ERROR);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case RunMode::EXECUTE_SCRIPT:
|
case RunMode::EXECUTE_SCRIPT:
|
||||||
|
|
|
@ -88,7 +88,7 @@ GeneralClientConnection* GeneralClientConnection::factory(
|
||||||
|
|
||||||
GeneralClientConnection* GeneralClientConnection::factory(
|
GeneralClientConnection* GeneralClientConnection::factory(
|
||||||
std::unique_ptr<Endpoint>& endpoint, double requestTimeout, double connectTimeout,
|
std::unique_ptr<Endpoint>& endpoint, double requestTimeout, double connectTimeout,
|
||||||
size_t numRetries, uint32_t sslProtocol) {
|
size_t numRetries, uint64_t sslProtocol) {
|
||||||
if (endpoint->encryption() == Endpoint::EncryptionType::NONE) {
|
if (endpoint->encryption() == Endpoint::EncryptionType::NONE) {
|
||||||
return new ClientConnection(endpoint, requestTimeout, connectTimeout,
|
return new ClientConnection(endpoint, requestTimeout, connectTimeout,
|
||||||
numRetries);
|
numRetries);
|
||||||
|
|
|
@ -75,7 +75,7 @@ class GeneralClientConnection {
|
||||||
|
|
||||||
static GeneralClientConnection* factory(
|
static GeneralClientConnection* factory(
|
||||||
std::unique_ptr<Endpoint>&, double, double, size_t,
|
std::unique_ptr<Endpoint>&, double, double, size_t,
|
||||||
uint32_t);
|
uint64_t);
|
||||||
|
|
||||||
//////////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////////
|
||||||
/// @brief return the endpoint
|
/// @brief return the endpoint
|
||||||
|
|
Loading…
Reference in New Issue