mirror of https://github.com/citusdata/citus.git
Revert "temp commit for multi task router"
This reverts commit c05ccde171ea254faffdc0e605e05e1b3ef0c576.pull/896/head
parent
66ab79bc42
commit
9c0bb3fb00
|
@ -127,32 +127,18 @@ RouterExecutablePlan(MultiPlan *multiPlan, MultiExecutorType executorType)
|
|||
List *workerDependentTaskList = NIL;
|
||||
bool masterQueryHasAggregates = false;
|
||||
|
||||
if (executorType == MULTI_EXECUTOR_TASK_TRACKER)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/* router executor cannot execute repartition jobs */
|
||||
if (dependedJobCount > 0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/* router executor cannot execute plans when master query is present */
|
||||
if (masterQuery != NULL)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/*
|
||||
* Multi task router executor can execute plans with zero task. This is currently
|
||||
* here for INSERT ... SELECT queries with zero shards.
|
||||
*/
|
||||
if (taskCount == 0)
|
||||
/* TODO: this is a hacky solution to allow 0 shard INSERT ... SELECT */
|
||||
if (masterQuery == NULL)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
/* router executor cannot execute queries that hit zero shards */
|
||||
if (taskCount == 0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/* check if the first task is a modify or a router task, short-circuit if so */
|
||||
workerTask = (Task *) linitial(workerTaskList);
|
||||
taskType = workerTask->taskType;
|
||||
|
@ -162,7 +148,18 @@ RouterExecutablePlan(MultiPlan *multiPlan, MultiExecutorType executorType)
|
|||
}
|
||||
|
||||
/* router executor cannot execute SELECT queries that hit more than one shard */
|
||||
if (taskCount != 1 && taskType == ROUTER_TASK)
|
||||
if (taskCount != 1)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
if (executorType == MULTI_EXECUTOR_TASK_TRACKER)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/* router executor cannot execute repartition jobs */
|
||||
if (dependedJobCount > 0)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
|
|
@ -101,14 +101,6 @@ FROM
|
|||
WHERE
|
||||
0 != 0;
|
||||
|
||||
INSERT INTO raw_events_second (value_2, value_1, value_3, value_4, user_id, time)
|
||||
SELECT
|
||||
value_2, value_1, value_3, value_4, user_id, time
|
||||
FROM
|
||||
raw_events_first
|
||||
WHERE
|
||||
user_id = 15 AND user_id = 16;
|
||||
|
||||
-- add one more row
|
||||
SET client_min_messages TO INFO;
|
||||
INSERT INTO raw_events_first (user_id, time, value_1, value_2, value_3, value_4) VALUES
|
||||
|
|
Loading…
Reference in New Issue