Skip to content
This repository has been archived by the owner on Apr 4, 2023. It is now read-only.

Commit

Permalink
Merge #577
Browse files Browse the repository at this point in the history
577: Fix deserialisation of NDJson documents in benchmarks r=irevoire a=loiclec

Previously, the first document in the NDJson file was read over and over again. So the `geo_point` benchmark was not working properly: it only indexed one document.

Co-authored-by: Loïc Lecrenier <loic@meilisearch.com>
  • Loading branch information
bors[bot] and Loïc Lecrenier authored Jul 5, 2022
2 parents 77c837f + 9bc7627 commit 62692c1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions benchmarks/benches/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ fn documents_from_jsonl(reader: impl Read) -> anyhow::Result<Vec<u8>> {

while reader.read_line(&mut buf)? > 0 {
documents.extend_from_json(&mut buf.as_bytes())?;
buf.clear();
}
documents.finish()?;

Expand Down

0 comments on commit 62692c1

Please sign in to comment.