feat: truncate request by time ranges (#262)

* feat: truncate request by time ranges

Signed-off-by: discord9 <discord9@163.com>

* fix: default time unit is millisecond

Signed-off-by: discord9 <discord9@163.com>

* refactor: per review

Signed-off-by: discord9 <discord9@163.com>

* add time ranges to truncate table expr

Signed-off-by: discord9 <discord9@163.com>

* chore: make all

Signed-off-by: discord9 <discord9@163.com>

* chore: fmt

Signed-off-by: discord9 <discord9@163.com>

* chore: make all

Signed-off-by: discord9 <discord9@163.com>

* chore: make all

Signed-off-by: discord9 <discord9@163.com>

---------

Signed-off-by: discord9 <discord9@163.com>
This commit is contained in:
discord9
2025-08-04 18:17:40 +08:00
committed by GitHub
parent 91c3d7b97a
commit ccfd4da48b
15 changed files with 5844 additions and 894 deletions
+7
View File
@@ -215,8 +215,15 @@ message CompactRequest {
message TruncateRequest {
uint64 region_id = 1;
oneof kind {
All all = 2;
TimeRanges time_ranges = 3;
}
}
// Truncate all data in region
message All {}
// The column definition of a region. Unlike the message `ColumnDef` in
// `ddl.proto` which is for clients outside GreptimeDB, this `RegionColumnDef`
// is for region requests use only. So it carries an extra field `column_id`