Hacker News new | ask | show | jobs
by tra3 43 days ago
I know that latest rails suggests SQLite as one of the production options. I don’t get how it’d work with concurrent access though. Time to look into it.
4 comments

Wal or wal2 can help you with that.
I'm using it w/ a Rust server and I can get up to 80k writes per second, 200k reads per second. You won't get that with other databases without paying a lot and doing a lot of special architecture.
That sounds like a lot. Is the rust process serving parallel requests?
Rechecked my benchmarks. 193,000 writes per second (rust), each write holds the lock for about 5 µs.

Full report here: https://github.com/pairshaped/gleam_sqlite_benchmarks/blob/m...

Obviously real world queries will vary, but I tried to be representative of the type of queries / updates I am sending.

Can use one sqlite per tenant or look into the new multi writer lib on github.
Because sqlite is extremely fast. Most projects won't hit its limits