apache / incubator-horaedb-meta

Meta service of HoraeDB cluster.

Home Page:https://horaedb.apache.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Timed out when creating a partitioned table with a large number of partitions

ZuLiangWang opened this issue · comments

Describe this problem
When create partition table with a large number of partitions, the client's request will time out.

Steps to reproduce
Execute create partitioned table like this:

CREATE TABLE `demo` (`name` string TAG, `value` double NOT NULL, `t` timestamp NOT NULL, TIMESTAMP KEY(t))
    PARTITION BY KEY(name) PARTITIONS 512
    ENGINE=Analytic with (enable_ttl='false')

Expected behavior
Successfully completed the creation of the partition table in a short time.

Additional Information
In the current implementation, the sub-table creation of the partition table is serial, maybe we need to optimize the sub-table creation process.

Perhaps a batch strategy can be used to optimize the creation process of sub-tables, when the number of sub-tables is greater than the number of nodes.