[fix](regression test) fix test_alter_colocate_table (#29009)

This commit is contained in:
yujun
2023-12-28 15:09:21 +08:00
committed by GitHub
parent 31b3be456c
commit 14c902b504
4 changed files with 17 additions and 16 deletions

View File

@ -116,18 +116,15 @@ public class ColocateGroupSchema implements Writable {
}
private void checkReplicaAllocation(PartitionInfo partitionInfo) throws DdlException {
for (ReplicaAllocation replicaAlloc : partitionInfo.idToReplicaAllocation.values()) {
if (!replicaAlloc.equals(this.replicaAlloc)) {
ErrorReport.reportDdlException(ErrorCode.ERR_COLOCATE_TABLE_MUST_HAS_SAME_REPLICATION_ALLOCATION,
this.replicaAlloc);
}
for (ReplicaAllocation alloc : partitionInfo.idToReplicaAllocation.values()) {
checkReplicaAllocation(alloc);
}
}
public void checkReplicaAllocation(ReplicaAllocation replicaAlloc) throws DdlException {
if (!replicaAlloc.equals(this.replicaAlloc)) {
ErrorReport.reportDdlException(ErrorCode.ERR_COLOCATE_TABLE_MUST_HAS_SAME_REPLICATION_ALLOCATION,
this.replicaAlloc);
replicaAlloc, this.replicaAlloc);
}
}

View File

@ -1110,7 +1110,7 @@ public enum ErrorCode {
ERR_COLOCATE_TABLE_MUST_BE_OLAP_TABLE(5063, new byte[]{'4', '2', '0', '0', '0'},
"Colocate table '%s' must be OLAP table"),
ERR_COLOCATE_TABLE_MUST_HAS_SAME_REPLICATION_ALLOCATION(5063, new byte[]{'4', '2', '0', '0', '0'},
"Colocate tables must have same replication allocation: %s"),
"Colocate tables must have same replication allocation: { %s } should be { %s }"),
ERR_COLOCATE_TABLE_MUST_HAS_SAME_BUCKET_NUM(5063, new byte[]{'4', '2', '0', '0', '0'},
"Colocate tables must have same bucket num: %s"),
ERR_COLOCATE_TABLE_MUST_HAS_SAME_DISTRIBUTION_COLUMN_SIZE(5063, new byte[]{'4', '2', '0', '0', '0'},