1
0
Fork 0

fix geo-index for cluster case

This commit is contained in:
Jan Christoph Uhde 2016-12-12 15:36:43 +01:00
parent 634eeabc0b
commit 1d5e28d969
2 changed files with 3 additions and 3 deletions

View File

@ -4417,8 +4417,8 @@ bool applyGeoOptimization(bool near, ExecutionPlan* plan, GeoIndexInfo& info){
// if executionNode is sort OR a filter without further sub conditions
// the node can be unlinked
if( info.executionNodeType == EN::SORT || !info.expressionParent){
if (!arangodb::ServerState::instance()->isCoordinator()) {
if(!info.expressionParent){
if (!arangodb::ServerState::instance()->isCoordinator() || info.executionNodeType == EN::FILTER) {
plan->unlinkNode(info.executionNode);
} else if (info.executionNodeType == EN::SORT){
//make sure sort is not reinserted in cluster

View File

@ -53,7 +53,7 @@ class SortNode : public ExecutionNode {
public:
SortNode(ExecutionPlan* plan, size_t id, SortElementVector const& elements,
bool stable)
: ExecutionNode(plan, id), _elements(elements), _stable(stable) {}
: ExecutionNode(plan, id), _reinsertInCluster(true), _elements(elements), _stable(stable) {}
SortNode(ExecutionPlan* plan, arangodb::velocypack::Slice const& base,
SortElementVector const& elements, bool stable);