From 7adc7157833d25235d3d89383324ea675f3d6ef3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Renault?= Date: Sat, 20 Jul 2024 17:15:33 +0200 Subject: [PATCH] Also count the direct_inserts --- milli/src/update/index_documents/cache.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/milli/src/update/index_documents/cache.rs b/milli/src/update/index_documents/cache.rs index 1c9079b1f..dc4404ab2 100644 --- a/milli/src/update/index_documents/cache.rs +++ b/milli/src/update/index_documents/cache.rs @@ -210,6 +210,10 @@ where } pub fn direct_insert(&mut self, key: &[u8], val: &[u8]) -> Result<(), grenad::Error> { + self.cbo_buffer.clear(); + self.cbo_buffer.extend_from_slice(self.prefix); + self.cbo_buffer.extend_from_slice(key); + self.conn.merge(&self.cbo_buffer, 1u32.to_ne_bytes()).unwrap(); self.sorter.insert(key, val) }