mirror of https://github.com/citusdata/citus.git
Disallow task-tracker queries on follower clusters
parent
c097bc9a01
commit
55992d4bc0
|
@ -27,6 +27,7 @@
|
|||
#include "commands/dbcommands.h"
|
||||
#include "distributed/citus_nodes.h"
|
||||
#include "distributed/connection_management.h"
|
||||
#include "distributed/metadata_cache.h"
|
||||
#include "distributed/multi_client_executor.h"
|
||||
#include "distributed/multi_physical_planner.h"
|
||||
#include "distributed/multi_server_executor.h"
|
||||
|
@ -163,6 +164,13 @@ MultiTaskTrackerExecute(Job *job)
|
|||
const char *transmitTrackerHashName = "Transmit Tracker Hash";
|
||||
List *jobIdList = NIL;
|
||||
|
||||
if (ReadFromSecondaries == USE_SECONDARY_NODES_ALWAYS)
|
||||
{
|
||||
ereport(ERROR, (errmsg("task tracker queries are not allowed while "
|
||||
"citus.use_secondary_nodes is 'always'"),
|
||||
errhint("try setting citus.task_executor_type TO 'real-time'")));
|
||||
}
|
||||
|
||||
/*
|
||||
* We walk over the task tree, and create a task execution struct for each
|
||||
* task. We then associate the task with its execution and get back a list.
|
||||
|
@ -190,7 +198,7 @@ MultiTaskTrackerExecute(Job *job)
|
|||
* assigning and checking the status of tasks. The second (temporary) hash
|
||||
* helps us in fetching results data from worker nodes to the master node.
|
||||
*/
|
||||
workerNodeList = ActiveReadableNodeList();
|
||||
workerNodeList = ActivePrimaryNodeList();
|
||||
taskTrackerCount = (uint32) list_length(workerNodeList);
|
||||
|
||||
taskTrackerHash = TrackerHash(taskTrackerHashName, workerNodeList);
|
||||
|
|
Loading…
Reference in New Issue