From 836992562c47898ab6521f33506242abf1326ec2 Mon Sep 17 00:00:00 2001 From: Sait Talha Nisanci Date: Tue, 19 May 2020 14:35:12 +0300 Subject: [PATCH] Error out if shard_replication_factor > 1 with repartitioning As we are removing the task tracker, we cannot switch to it if shard_replication_factor > 1. In that case, we simply error out. --- src/backend/distributed/executor/multi_server_executor.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/backend/distributed/executor/multi_server_executor.c b/src/backend/distributed/executor/multi_server_executor.c index 77527e4d0..2a02b52d6 100644 --- a/src/backend/distributed/executor/multi_server_executor.c +++ b/src/backend/distributed/executor/multi_server_executor.c @@ -111,7 +111,8 @@ JobExecutorType(DistributedPlan *distributedPlan) } if (HasReplicatedDistributedTable(distributedPlan->relationIdList)) { - return MULTI_EXECUTOR_TASK_TRACKER; + ereport(ERROR, (errmsg( + "repartitioning with shard_replication_factor > 1 is not supported"))); } return MULTI_EXECUTOR_ADAPTIVE; }