KV: don't retrieve values for write ops #873
No reviewers
Labels
No labels
action
check-aws
action
discussion-needed
action
for-external-contributors
action
for-newcomers
action
more-info-needed
action
need-funding
action
triage-required
kind
correctness
kind
ideas
kind
improvement
kind
performance
kind
testing
kind
usability
kind
wrong-behavior
prio
critical
prio
low
scope
admin-api
scope
background-healing
scope
build
scope
documentation
scope
k8s
scope
layout
scope
metadata
scope
ops
scope
rpc
scope
s3-api
scope
security
scope
telemetry
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Deuxfleurs/garage#873
Loading…
Reference in a new issue
No description provided.
Delete branch "marvinj97/garage:perf/kv/insert-no-return"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
As described in #851, return values in KV write ops are never used, so it is unnecessarily performing read ops (possibly with disk I/O) in the write hot path. But I haven't benchmarked the change in performance.
SQLite could probably use INSERT ... ON CONFLICT(REPLACE)
Darn, you beat me to it ^^ That does feel like a good improvement!
For reference, here is a little PutObject benchmark for this change.
Before (as seen in #851) :
With this change :
There does appear to be a performance benefit: the second benchmark stays above 500#/s for longer.
I have got the diff for the
INSERT OR REPLACE
in SQLite but I don't really have benchmark data for it, so I can't say how that would perform.JKR
@withings
The benchmark images are broken unfortunatelyLGTM