mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-19 16:20:50 +00:00
Fix 02982_parallel_replicas_unexpected_cluster
This commit is contained in:
parent
5347754aed
commit
fc693cc982
@ -736,6 +736,12 @@ bool canUseParallelReplicasOnInitiator(const ContextPtr & context)
|
|||||||
return cluster->getShardsInfo().at(shard_num - 1).getAllNodeCount() > 1;
|
return cluster->getShardsInfo().at(shard_num - 1).getAllNodeCount() > 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (cluster->getShardCount() > 1)
|
||||||
|
throw DB::Exception(
|
||||||
|
ErrorCodes::UNEXPECTED_CLUSTER,
|
||||||
|
"`cluster_for_parallel_replicas` setting refers to cluster with {} shards. Expected a cluster with one shard",
|
||||||
|
cluster->getShardCount());
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user