News for hackers. Stuff that matters.
Re:Twelve years of distributed SQLite by chasil on Saturday October 24, 2026 @12:08AM (#50218298)
I have never examined this in any detail before. It looks far easier than the mass majority of clustered database architectures.

https://rqlite.io/

Re:Twelve years of distributed SQLite by qaq on Saturday October 24, 2026 @01:21AM (#50218534)
using it for control layer pretty happy so far
Re:Twelve years of distributed SQLite by gizzlon on Saturday October 24, 2026 @04:32AM (#50219282)
can you query the local rqlite, or do you always have to go to the leader?
Re:Twelve years of distributed SQLite by pizzafeelsright on Saturday October 24, 2026 @06:14AM (#50219796)
docs - Queries, by default, are also serviced by the cluster Leader.

it is great, fun, easy.

Re:Twelve years of distributed SQLite by jasonjayr on Saturday October 24, 2026 @11:01AM (#50221926)
Last time I looked into it, you CAN bypass the rqlite raft layer, and hit the local sqlite directly, but you are not guaranteed consistency. Depending on your use case, that may be okay.
Re:Twelve years of distributed SQLite by lukaslalinsky on Saturday October 24, 2026 @06:14AM (#50219795)
How long have you been using it? I've always been disappointed with similar systems, etcd including.
Re:Twelve years of distributed SQLite by qaq on Saturday October 24, 2026 @06:50PM (#50226231)
It's basically holding tenant and operator master registry that app nodes pull down resulting in very light load on rqlite. The architecture is resilient to control layer being down (just can't provision new tenants).
Re:Twelve years of distributed SQLite by a3nz3g on Saturday October 24, 2026 @12:03AM (#50218267)
Like the idea of distributed SQLite, but do we have benchmark? What use cases it has advantage?
Re:Twelve years of distributed SQLite by esafak on Friday October 23, 2026 @11:17PM (#50218080)
Very timely for me. I run dqlite in a small cluster and I'm looking to move off it to something more robust. What's recommended in this regime?
Re:Twelve years of distributed SQLite by oblio on Saturday October 24, 2026 @12:08AM (#50218300)
What kind of issues did you run into?
Re:Twelve years of distributed SQLite by esafak on Saturday October 24, 2026 @12:11AM (#50218314)
Loads of '500 database locked'. https://github.com/canonical/dqlite/issues/908
Re:Twelve years of distributed SQLite by gregsadetsky on Saturday October 24, 2026 @04:29PM (#50224909)
Re:Twelve years of distributed SQLite by esafak on Saturday October 24, 2026 @11:44PM (#50228099)
Yes, as I noted in the issue. dqlite is the kind of "load bearing" project that would benefit from formal verification: https://ubuntu.com/blog/hunting-a-16-year-old-sqlite-bug-wit...
Re:Twelve years of distributed SQLite by gregsadetsky on Sunday October 25, 2026 @08:26AM (#50230833)
Ah yes, sorry - saw your name there too but didn’t read closely enough.

Are you still going to use dqlite after this experience, or has it shaken your confidence in it? Also what’s been your experience with microk8s itself - I hadn’t heard of it before

Re:Twelve years of distributed SQLite by esafak on Sunday October 25, 2026 @10:58AM (#50232229)
microk8s is all right, but I don't have the experience with the alternatives to be able to make a comparison. For dqlite I will switch. This was a very conspicuous bug, so I am surprised I was the first person to report it. I want something battle tested for control plane.
Re:Twelve years of distributed SQLite by feverzsj on Saturday October 24, 2026 @12:26AM (#50218363)
There is also hctree from sqlite.
Re:Twelve years of distributed SQLite by tra3 on Saturday October 24, 2026 @12:33AM (#50218382)
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.
Re:Twelve years of distributed SQLite by bendangelo on Saturday October 24, 2026 @01:55AM (#50218661)
Can use one sqlite per tenant or look into the new multi writer lib on github.
Re:Twelve years of distributed SQLite by ImJasonH on Saturday October 24, 2026 @06:58AM (#50220084)
Re:Twelve years of distributed SQLite by npn on Saturday October 24, 2026 @12:40AM (#50218399)
Wal or wal2 can help you with that.
Re:Twelve years of distributed SQLite by nchmy on Saturday October 24, 2026 @08:55AM (#50220816)
Because sqlite is extremely fast. Most projects won't hit its limits
Re:Twelve years of distributed SQLite by rapind on Saturday October 24, 2026 @05:16PM (#50225401)
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.
Re:Twelve years of distributed SQLite by tra3 on Saturday October 24, 2026 @05:41PM (#50225648)
That sounds like a lot. Is the rust process serving parallel requests?
Re:Twelve years of distributed SQLite by rapind on Saturday October 24, 2026 @06:01PM (#50225808)
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.

Re:Twelve years of distributed SQLite by brooksbp on Saturday October 24, 2026 @01:09AM (#50218493)
Was a fun read until the end where the author made damn sure that history records who drew the blueprint.
Re:Twelve years of distributed SQLite by pbowyer on Saturday October 24, 2026 @03:58AM (#50219132)
Seems fair to me. The VC-backed SQLite services have been shouting about their services as if they came up with the idea, and this only balances that out.

He's right that histories start too late, and I'd like to see more posts like this that trace the history back further than the last 5 years. Like for databases, a lot can go back 20+ years and it's good to read how the idea came about (independently from many people), how it developed over time and why.

Re:Twelve years of distributed SQLite by Scaevolus on Saturday October 24, 2026 @02:31AM (#50218785)
"Honesty" is what crossed the threshold for me. It's pretty weird to spend 12 years on something and not bother to write the thousand word history yourself.
Re:Twelve years of distributed SQLite by piterrro on Saturday October 24, 2026 @01:48AM (#50218626)
Having used D1 in production - it's not very reliable. There was a comment on HN from one of D1 devs [1] saying that D1 is a sql wrapper on top of durable objects that mimicks sqlite distributed like nature.

> I'll let you in on a sort of dirty secret: It's almost always better to use Durable Objects storage, rather than D1. Even if you only want a single global database, it's better to implement that as a singleton Durable Object, than by using D1. Because that's all D1 itself actually is: a singleton Durable Object that exposes an API to its SQLite database. It's just a wrapper.

[1] https://news.ycombinator.com/item?id=48611834

Re:Twelve years of distributed SQLite by unconscionable on Saturday October 24, 2026 @04:12AM (#50219202)
Completely. D1 flaky as hell!
Re:Twelve years of distributed SQLite by ruther4d on Saturday October 24, 2026 @07:19AM (#50220205)
D1 also gives read replication and point in time recovery, but my biggest issue with it is you can’t create D1 dbs dynamically like you can with durable objects so things like tenancy are harder
Re:Twelve years of distributed SQLite by oblio on Saturday October 24, 2026 @06:22PM (#50225998)
Aren't Durable Objects like... proprietary? Tied to a specific cloud platform?
Re:Twelve years of distributed SQLite by ruther4d on Saturday October 24, 2026 @06:59PM (#50226305)
Re:Twelve years of distributed SQLite by Kinrany on Saturday October 24, 2026 @01:50AM (#50218636)
Is there a project that does all of these together?

- embeddable like sqlite

- clustered like dqlite

- has a standalone node like rqlite

- can be backed up to S3 like litesteeam

- optionally AP like cr-sqlite alongside CP

Re:Twelve years of distributed SQLite by punnerud on Saturday October 24, 2026 @02:48AM (#50218843)
https://github.com/punnerud/mpedb is not there yet, focused on sync between sqlite3, Postgresql and Oracle. Shown that concurrent writes to sqlite3 is possible at the speed of Postgresql (My own project)
Re:Twelve years of distributed SQLite by thriftwy on Saturday October 24, 2026 @05:48AM (#50219644)
This sounds a lot like Apache Ignite 2.x, though it does not have SQLite's level of polish.
Re:Twelve years of distributed SQLite by Kinrany on Saturday October 24, 2026 @08:14AM (#50220534)
It's never going to be embeddable, no?
Re:Twelve years of distributed SQLite by thriftwy on Saturday October 24, 2026 @08:33AM (#50220658)
It is a set of Java dependencies so a full data-bearing Ignite node will happily be an in-process part of your Java monolithic app or microservice. It has likewise bindings for .Net and some other languages but not so seamless as in case of JVM.
Re:Twelve years of distributed SQLite by bfren on Saturday October 24, 2026 @02:47AM (#50218835)
I maintain one of the client libraries for rqlite - I’ve found it an excellent concept really well implemented. One of my favourite bits is it gives you back json making Dapper-like mapping super easy in .NET and I suspect other languages.
Re:Twelve years of distributed SQLite by joostdecock on Saturday October 24, 2026 @03:28AM (#50219006)
We use rqlite in production, it's the database we chose for (the control plane of) an open source observability solution we're building (morio.it).

Just came here to say two things:

- rqlite is amazing and warmly recommend - Philip is an exceptionally dedicated, kind, and helpful maintainer

5 stars, no notes. Thank you Philip, I'm eternally grateful for all your great work.

Re:Twelve years of distributed SQLite by klamann on Saturday October 24, 2026 @04:17AM (#50219224)
If you don't get any joy out of writing about your personal experiences in your own voice, why bother writing about them at all?
Re:Twelve years of distributed SQLite by phrotoma on Saturday October 24, 2026 @06:52AM (#50220045)
I get zero LLM vibes from this blog post.
Re:Twelve years of distributed SQLite by AgentME on Saturday October 24, 2026 @07:56AM (#50220436)
It's loaded with it to my eyes. (Pangram also agrees and flags the whole post as AI generated.)

  # 2014: rqlite
  The need was concrete.

  # Before 2014, and alongside it
  Two things deserve mention for honesty’s sake.
(the above line is extremely typical of Claude Opus 4.8 and 5.0)

  [...] and the main difference is of one of packaging:

  # What the twelve years show
  Three things, I think.
  The core was right. [...] Nobody has found a reason to stop doing it.
  The design space has three corners, and they appeared in order.
(What order? The corners of this design space, which aren't spelled out until the following sentence, don't have any other natural ordering. This type of misapplied flourish feels very typical of LLMs.)
Re:Twelve years of distributed SQLite by bomewish on Saturday October 24, 2026 @10:06AM (#50221359)
Yeah it felt like claudeslop to me too — and such a strange choice. Maybe dude dictated it and said Claude to write it up. Save some time. Even so.
Re:Twelve years of distributed SQLite by dizhn on Saturday October 24, 2026 @07:43AM (#50220349)
There are a bunch but in my opinion not conclusive.
Re:Twelve years of distributed SQLite by klamann on Saturday October 24, 2026 @09:40AM (#50221130)
I envy you. For better or worse, Claude is the author I've read the most in this year. There's a handful of human authors I know well enough so that I would recognize a text that was written by them. With LLMs, it's much easier than with humans, since the current generation of LLMs seems utterly incapable of changing their style.
Re:Twelve years of distributed SQLite by senderista on Saturday October 24, 2026 @01:57PM (#50223576)
If you talk to Claude all day every day like some of us are forced to, it's plain as day.
Re:Twelve years of distributed SQLite by phrotoma on Tuesday October 27, 2026 @05:50AM (#50256677)
Huh, yeah I don't do much of that. I genuinely appreciate these replies. It's good to know where my blind spots are. Thank you!
Re:Twelve years of distributed SQLite by formerly_proven on Saturday October 24, 2026 @06:08AM (#50219759)
Kinda grating to have the story of your project told in default Claudese, to be honest.
Re:Twelve years of distributed SQLite by gizzlon on Saturday October 24, 2026 @04:31AM (#50219277)
I've been looking for a reason to use rqlite, but so far sqlite + litestream have been safe enough (some dataloss acceptable in extreme cases)

My understanding is that rqlite gives you "stored in more than place" guarantees, which is nice if you need it. Much slower than a 1 node db though.

Re:Twelve years of distributed SQLite by vikrantrathore on Saturday October 24, 2026 @04:52AM (#50219374)
Its funny, when I was reading part time parliament paper (paxos) and while learning zig and odin language created a pure paxos library and then the first application for that library was to build a multi-master sqlite. The two approaches I took are very different in case of zig I build zaxonlite (https://github.com/insanai/zaxonlite) and have a benchmark on it that includes rqlite. It uses WAL replication as strategy. The second attempt I tried in odin is sqlodin (https://github.com/insanai/sqlodin), in this the system does not use WAL but run sql query on each node, as result subset of sql query in sqlite are not supported.
Re:Twelve years of distributed SQLite by thadt on Saturday October 24, 2026 @08:42AM (#50220719)
Wow, a 155 page book for a relatively new project is interesting - what was your workflow for that? It looks mostly generated - is it used in its entirety as context to a top-level agent when working on new features, or are you directing it to just take relevant subsections? Why the PDF output (it does look nice)?
Re:Twelve years of distributed SQLite by vikrantrathore on Sunday October 25, 2026 @09:08AM (#50231161)
I do not use book for a context, book is the outcome of the development. I am still old school I feel any product should have good documentation and should be available offline, also personally I like physical things so many of them will print and read. I follow a rigorous process I used to follow since 1998, without AI, which is write something like PEP or RFC before starting work on things. So if you look at the whole project it has design records and each contains details. I read through the docs, even though I use AI from time to time. I used to write a lot of restructuredtext (RST) docs. So I wanted to move the whole pipeline to rust, I used to use latex for it earlier but then wanted to move to typst. So for it wrote another system which helps me with website, html, pdf. You can take a look if you like the project is https://github.com/insanai/guidedog, sibuna also I ported from typst pipeline to guidedog which uses rst markup. If you want to look at development part I especially use dsc (short for discussions) so if you type `guidedog dsc --help` to see the details.
Re:Twelve years of distributed SQLite by jwr on Saturday October 24, 2026 @05:58AM (#50219701)
So, has this been Jepsen-tested yet?

Because if it hasn't, it's likely there are problems lurking.

Re:Twelve years of distributed SQLite by tmsln on Saturday October 24, 2026 @08:56AM (#50220822)
Re:Twelve years of distributed SQLite by mxey on Saturday October 24, 2026 @12:02PM (#50222585)
“Their tests showed that rqlite maintains linearizability of record insertion and modification, provided strong read consistency is enabled.”

The rqlite docs however tell you to never use Strong mode and that Linearizable is sufficient. https://rqlite.io/docs/api/read-consistency/#strong

Re:Twelve years of distributed SQLite by otterley on Saturday October 24, 2026 @02:30PM (#50223831)
This smells a lot like the situation MongoDB had in its early years that made it lose a lot of trust in the community.
Re:Twelve years of distributed SQLite by mxey on Monday October 26, 2026 @04:07AM (#50240614)
Looking further into this: The Linearizable mode is newer than the test, so we don’t know if it would have passed.

https://philipotoole.com/faster-reads-same-guarantees-linear...

Re:Twelve years of distributed SQLite by AgentME on Saturday October 24, 2026 @06:40AM (#50219960)
The comparisons between various projects, including between rqlite and Litestream, were interesting. (rqlite uses a consensus algorithm between nodes to keep them synced and allow changing the primary node, while Litestream just syncs itself to S3 so another node could take over with the data from there.)

I fully expected the article to get into D1 shortly and mention how that's about the same relationship between Cloudflare Durable Objects (which D1 is based on) and celld, an open source reimplementation of Cloudflare Durable Objects which writes to S3. But then the article treats D1 with a very sudden snarky disinterest, and then the final section feels very awkwardly defensive of rqlite and defeatist.

Re:Twelve years of distributed SQLite by mmnfrdmcx on Saturday October 24, 2026 @06:44AM (#50219987)
As someone who loved sqlite and the simplicity, the truth is that with agents I am finding it is extremely easy to manage postgres and it is realyl nice having all the SQL features of postgres -- sqlite is quite limiting in a lot of SQL. So if you are considering remote sqlite and all that, feels a better time than ever to just use a database server. Of course, sqlite is amazing for local tools etc.
Re:Twelve years of distributed SQLite by mxey on Saturday October 24, 2026 @11:56AM (#50222511)
How are agents helping you? What was the trouble with Postgres before?
Re:Twelve years of distributed SQLite by oblio on Saturday October 24, 2026 @06:25PM (#50226042)
My guess is that coding agents expose deep documentation and advanced patterns better or least faster that wading through everything.
Re:Twelve years of distributed SQLite by mmnfrdmcx on Monday October 26, 2026 @04:50AM (#50240953)
Unfamiliarity/unwillingness to deal with the infrastructure admin
Re:Twelve years of distributed SQLite by smellf on Saturday October 24, 2026 @01:02PM (#50223112)
I've had the exact same experience. In the before-time I often reflected on how my love of sqlite was borderline irrational for what it is. Now, in a few projects I've let the LLM do postgres, and it's so nice having the pain if a db server mostly just handled. Still choose sqlite for anything embedded or without a hosted server.
Re:Twelve years of distributed SQLite by canadiantim on Saturday October 24, 2026 @02:52PM (#50223987)
It’ll be a fine day when phones can use an embedded Postgres
Re:Twelve years of distributed SQLite by bob1029 on Saturday October 24, 2026 @04:22PM (#50224813)
I am the same way with MSSQL. I used to avoid it like the plague because of how the permissions/logins/everything worked. Now I can throw a T-SQL script at it in a few seconds to make it behave.
Re:Twelve years of distributed SQLite by rapind on Saturday October 24, 2026 @05:08PM (#50225312)
The problem is "remote" SQLite. Just run a "single" beefier box with in-process SQLite and Litestream backups to object storage and never have to think about RDBMS again. I'd wager there are 90%+ applications that would be better served, more performant, and cheaper with this design.

I'm able to handle around 200k/s on a sub $100 box. https://github.com/pairshaped/gleam_sqlite_benchmarks/blob/m...

Re:Twelve years of distributed SQLite by mmnfrdmcx on Monday October 26, 2026 @04:48AM (#50240942)
Equally easy to set up postgres with all teh bells and whistles you like using AI nowadays
Re:Twelve years of distributed SQLite by preisschild on Saturday October 24, 2026 @12:10PM (#50222655)
I'd love to see a distributed sqlite solution using something like OmniPaxos[1] being used for consensus instead of raft

[1]: https://github.com/haraldng/omnipaxos

Re:Twelve years of distributed SQLite by senderista on Saturday October 24, 2026 @01:56PM (#50223570)
Really disappointing to see that someone can't be bothered to tell the story of their own project in their own words.
Re:Twelve years of distributed SQLite by gregsadetsky on Saturday October 24, 2026 @04:46PM (#50225066)
I feel like there should be a comparison table listing all of these engines and how they compare on their external dependencies, whether a single leader/any node can write, their shape (embeddable library vs server), etc.

IMHO support for transactions is a pretty important dividing line. Some engines support full SQLite transactions while others - like rqlite - don't officially support BEGIN/COMMIT [0], which matters if you rely on multi-statement transactions.

A friend/colleague has been building a pure-Python client for dqlite [1] (DB-API and SQLAlchemy), which may interest folks here. dqlite has full support for transactions, and like rqlite doesn't have external dependencies (ie no S3/Consul).

No knock on rqlite or any other engine - dqlite has warts too [2].

[0] https://rqlite.io/docs/faq/#does-rqlite-support-transactions

[1] https://github.com/letsdiscodev/python-dqlite-dbapi

[2] https://github.com/canonical/dqlite/issues/882 opened by my friend, https://github.com/canonical/dqlite/issues/908 , https://github.com/canonical/dqlite/issues/912 opened by me