Then there could be some opportunities that one SG belongs to many regions (for 
adding regions for existed SG). If so, I think the following design may be more 
formal. What do you think?

ALTER STORAGE GROUP <sgName> ADD (DATA | SCHEMA) REGION

And I think we should also display the region count in SHOW STROAGE GROUP;

在 2022/8/18 11:06,“Jialin Qiao”<[email protected]> 写入:

    Hi,

    We will create a  region for this storage group, and allocate all replicas
    of this region to datanodes. Then, newly created data partition could be
    routed to  this region.

    1. Does the exist data under the prefixPath will be automatically migrated
    to the new region?

    Currently, no.
    But we could also migrate some existing data by some sql.

    2. Does the prefixPath must be a storage group name, or any arbitrary
    prefix path?

    Yes.

    Thanks,
    Jialin Qiao


    Eric Pai <[email protected]> 于2022年8月18日周四 11:00写道:

    > Hi,
    >
    > Could you explain what will happen after a region being created manually
    > in detail? And I have some questions about this SQL
    > 1. Does the exist data under the prefixPath will be automatically migrated
    > to the new region?
    > 2. Does the prefixPath must be a storage group name, or any arbitrary
    > prefix path?
    >
    > 在 2022/8/18 10:50,“Yongzao Dan”<[email protected]> 写入:
    >
    >     Hi,
    >     &nbsp; I'm planning to add a SQL for IoTDB cluster version. Here are
    > the details of this SQL:
    >
    >
    >     &nbsp; Motivation:&nbsp;We don't have enough evidence to design an
    > optimal&nbsp;RegionGroup&nbsp;expansion algorithm yet.&nbsp;
    >     If a large number of devices are created in a StorageGroup and the
    > SeriesPartitionSlot is filled, the current algorithm cannot
    > expand&nbsp;RegionGroup&nbsp;anymore.&nbsp;
    >     Therefore, we need a special SQL to enable DBA
    > expand&nbsp;RegionGroup&nbsp;manually.
    >
    >
    >     &nbsp; Syntax Definition: create (data | schema) region on
    > prefixPath(Represent a specific StorageGroup)
    >
    >
    >     &nbsp; Function Definition: Create a new data/schema RegionGroup for
    > the specific StorageGroup.
    >
    >
    >
    > 
------------------------------------------------------------------------------------------------------------
    >
    >
    >     Yongzao Dan,
    >     School of Software, Tsinghua University
    >
    >

Reply via email to