1
0
Fork 0

Merge branch 'devel' of github.com:triAGENS/ArangoDB into devel

This commit is contained in:
Willi Goesgens 2014-10-29 16:22:44 +01:00
commit 9934010c0a
4 changed files with 9 additions and 6 deletions

View File

@ -126,7 +126,7 @@ AqlItemBlock::AqlItemBlock (Json const& json) {
Json lowBound(data.at(static_cast<int>(posInData++)));
Json highBound(data.at(static_cast<int>(posInData++)));
int64_t low = JsonHelper::getNumericValue<int64_t>(lowBound.json(), 0);
int64_t high = JsonHelper::getNumericValue<int64_t>(lowBound.json(), 0);
int64_t high = JsonHelper::getNumericValue<int64_t>(highBound.json(), 0);
AqlValue a(low, high);
try {
setValue(i, column, a);

View File

@ -4622,7 +4622,7 @@ int RemoteBlock::initializeCursor (AqlItemBlock* items, size_t pos) {
ENTER_BLOCK
// For every call we simply forward via HTTP
Json body(Json::Array, 2);
Json body(Json::Array, 4);
if (items == nullptr) {
// first call, items is still a nullptr
body("exhausted", Json(true))
@ -4630,7 +4630,9 @@ int RemoteBlock::initializeCursor (AqlItemBlock* items, size_t pos) {
}
else {
body("pos", Json(static_cast<double>(pos)))
("items", items->toJson(_engine->getQuery()->trx()));
("items", items->toJson(_engine->getQuery()->trx()))
("exhausted", Json(false))
("error", Json(false));
}
std::string bodyString(body.toString());

View File

@ -1816,7 +1816,7 @@ namespace triagens {
double estimateCost () const override final {
double depCost = _dependencies.at(0)->getCost();
if (depCost <= 2.0) {
if (depCost <= 3.0) {
return depCost;
}
return log(depCost) * depCost;

View File

@ -225,7 +225,8 @@ int Optimizer::createPlans (ExecutionPlan* plan,
estimatePlans();
sortPlans();
/*
#if 0
// Only for debugging:
std::cout << "Optimisation ends with " << _plans.size() << " plans."
<< std::endl;
for (auto p : _plans.list) {
@ -233,7 +234,7 @@ int Optimizer::createPlans (ExecutionPlan* plan,
std::cout << "costing: " << p->getCost() << std::endl;
std::cout << std::endl;
}
*/
#endif
return TRI_ERROR_NO_ERROR;
}