Skip to content

Commit 3feaf90

Browse files
committed
fix(cubestore): Temprary remove min and max fields from chunks meta in index shapshots
1 parent 8149d7b commit 3feaf90

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

rust/cubestore/cubestore/src/metastore/chunks.rs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,13 @@ impl Chunk {
5353
self.partition_id
5454
}
5555

56+
pub fn unset_min_max(&self) -> Self {
57+
let mut to_update = self.clone();
58+
to_update.min = None;
59+
to_update.max = None;
60+
to_update
61+
}
62+
5663
pub fn set_partition_id(&self, partition_id: u64) -> Self {
5764
let mut to_update = self.clone();
5865
to_update.partition_id = partition_id;

rust/cubestore/cubestore/src/queryplanner/planning.rs

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1300,6 +1300,17 @@ fn pick_partitions(
13001300
continue;
13011301
}
13021302

1303+
//FIXME !!!!! emergency fix for APM, might break the limit pushdown, need to be solved on
1304+
//another way
1305+
let chunks = chunks
1306+
.into_iter()
1307+
.map(|c| {
1308+
let id = c.id;
1309+
let chunk = c.into_row().unset_min_max();
1310+
IdRow::new(id, chunk)
1311+
})
1312+
.collect::<Vec<_>>();
1313+
13031314
partition_snapshots.push(PartitionSnapshot { chunks, partition });
13041315
}
13051316
log::trace!(

0 commit comments

Comments
 (0)