mirror of
https://gitee.com/milvus-io/milvus.git
synced 2024-12-01 03:18:29 +08:00
Fix test_compact_cross_partition (#20547)
Signed-off-by: longjiquan <jiquan.long@zilliz.com> Signed-off-by: longjiquan <jiquan.long@zilliz.com>
This commit is contained in:
parent
e217b951ee
commit
b11df55499
@ -1161,8 +1161,6 @@ class TestCompactionOperation(TestcaseBase):
|
||||
# create collection and partition
|
||||
collection_w = self.init_collection_wrap(name=cf.gen_unique_str(prefix), shards_num=1)
|
||||
partition_w = self.init_partition_wrap(collection_wrap=collection_w)
|
||||
collection_w.create_index(ct.default_float_vec_field_name, ct.default_index)
|
||||
log.debug(collection_w.index())
|
||||
|
||||
# insert
|
||||
df = cf.gen_default_dataframe_data(tmp_nb)
|
||||
@ -1171,6 +1169,10 @@ class TestCompactionOperation(TestcaseBase):
|
||||
partition_w.insert(df)
|
||||
assert collection_w.num_entities == tmp_nb * 2
|
||||
|
||||
# compaction only applied to indexed segments.
|
||||
collection_w.create_index(ct.default_float_vec_field_name, ct.default_index)
|
||||
log.debug(collection_w.index())
|
||||
|
||||
# compact
|
||||
collection_w.compact()
|
||||
collection_w.wait_for_compaction_completed()
|
||||
|
Loading…
Reference in New Issue
Block a user