@fjallrs.bsky.social
82 followers 35 following 130 posts
Snazzy Rust KV store @ https://github.com/sponsors/fjall-rs
Posts Media Videos Starter Packs
fjallrs.bsky.social
Without having numbers (right now), LMDB will probably read absurdly fast, while not so much space- or write efficient.
Most, if not all data, fits into RAM here. Would be interesting to benchmark 100s of GBs.

But I found redb to be slower (sometimes much slower) than LMDB, pretty much always.
fjallrs.bsky.social
And here's another read-heavy bench with 4K values, 5% sync random updates and 95% Zipfian reads.

ReDB uses 4x more disk space, and writes 6x slower. Interestingly, it's also ~5x slower in point reads - I think ReDB is not handling large values well; haven't read too much into its implementation.
fjallrs.bsky.social
Synchronous writes (fsync) I might add
fjallrs.bsky.social
95% Zipfian reads, 5% random updates on a Kingston PLP SSD with 16K JSON blobs - sled DNF! (OOM)

fjall uses LZ4 compression
Reposted
bad-example.com
constellation runs on a bare metal server with 4 dedicated CPU cores, 16GiB memory, 1TiB fast NVMe SSD attached, and 500mbit unmetered network connection.
why.bsky.team
turns out raspberry pis are really fast these days
fjallrs.bsky.social
**slightly slower in reading
fjallrs.bsky.social
sled (bloodstone) is not in the bench too rn, because you can't compile it next to sled w/ compression; plus it's super unstable - in general I found it to be faster in writing, smaller on disk, but similar or slightly slower in writing than sled 0.x...
fjallrs.bsky.social
Blob GC working again (now fully automatic) - much less impact on foreground work (old GC was stop-the-world)
fjallrs.bsky.social
Hopefully I will have results in 6 hours 👀
fjallrs.bsky.social
Noo 🥲

I wanted to expand it to a 1-hour run but it crashed because of a bug in the workload (I think), in the middle of the night.
Reposted
fjallrs.bsky.social
If you sponsor NOW (github.com/sponsors/fja...), you can get an exclusive preview of version 3!!

jk I pushed the first pre-release to crates.io - it's unstable though! Breakages guaranteed, and some APIs are missing!

bye
Sponsor @fjall-rs on GitHub Sponsors
Support fjall-rs's open source work
github.com
fjallrs.bsky.social
If you sponsor NOW (github.com/sponsors/fja...), you can get an exclusive preview of version 3!!

jk I pushed the first pre-release to crates.io - it's unstable though! Breakages guaranteed, and some APIs are missing!

bye
Sponsor @fjall-rs on GitHub Sponsors
Support fjall-rs's open source work
github.com
fjallrs.bsky.social
Looks like the default fillfactor is 100%, which should be good for disk space. So it's probably dead row overhead and lack of page compression (?) plus maybe secondary indexes.
fjallrs.bsky.social
But yeah, it feels like things are slotting into place.

I have more than 50 git stashes and branches floating around... it's been a bit messy, but getting there.
fjallrs.bsky.social
I think I was lucky to fall into the pit of success because I think I made more progress the last two days than the last two months combined...

V3 pre-release(s) very soon... 👀
fjallrs.bsky.social
Add to that, sweeping API changes for better ergonomics that easily touch over a hundred files - Rust's doctests are a godsend here, I would have gone insane already without them
fjallrs.bsky.social
ngl v3 is a bit more involved than I originally planned or anticipated; I don't want breaking changes for a while, so it becomes this chase of making sure everything is really future-proof
fjallrs.bsky.social
Yeah a little bit; new disk format, changed some APIs to be nicer etc. etc.
fjallrs.bsky.social
I will never do a major release like this again
fjallrs.bsky.social
I really dread having to some day write a quick_cache replacement, tailored for lsm-tree
fjallrs.bsky.social
Ubuntu 22.04.5 - only really using write(), fsync() and pread()
fjallrs.bsky.social
Nvm getting corruptions on XFS too... sooo... kernel bug??