Skip to content

Commit

Permalink
Allow threading on get operations (#103)
Browse files Browse the repository at this point in the history
  • Loading branch information
GodTamIt authored Dec 13, 2023
1 parent 8e485e2 commit 3e64dc4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rdict.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1175,7 +1175,7 @@ fn get_batch_inner<'a>(
for key in key_list {
keys.push(encode_key(key, raw_mode)?);
}
let values = db.batched_multi_get_cf_opt(cf, &keys, false, read_opt);
let values = py.allow_threads(|| db.batched_multi_get_cf_opt(cf, &keys, false, read_opt));
let result = PyList::empty(py);
for v in values {
match v {
Expand Down

0 comments on commit 3e64dc4

Please sign in to comment.