KV: don't retrieve values for write ops #873

Merged
lx merged 3 commits from marvinj97/garage:perf/kv/insert-no-return into main 2024-09-10 09:06:29 +00:00
Showing only changes of commit 8062ec7b4b - Show all commits

View file

@ -12,7 +12,7 @@ fn test_suite(db: Db) {
// ---- test simple insert/delete ----
assert!(tree.insert(ka, va).unwrap().is_none());
assert!(tree.insert(ka, va).is_ok());
assert_eq!(tree.get(ka).unwrap().unwrap(), va);
assert_eq!(tree.len().unwrap(), 1);
@ -50,7 +50,7 @@ fn test_suite(db: Db) {
assert!(iter.next().is_none());
drop(iter);
assert!(tree.insert(kb, vc).unwrap().is_none());
assert!(tree.insert(kb, vc).is_ok());
assert_eq!(tree.get(kb).unwrap().unwrap(), vc);
let mut iter = tree.iter().unwrap();