News for hackers. Stuff that matters.
Re:Siren Call of SQLite on the Server by cjs_ac on Tuesday February 18, 2025 @07:37AM (#43088790)
The application I'm building (I haven't launched yet) has one database per customer that tracks the things the customer does in the application, plus a single database that tracks the metadata about all of the customers. The metadata changes very slowly (each customer will probably make at most one update per year), so there will be (almost) no write contention on the metadata database. Each customer has an id (a random 64-bit integer) which is used (in hexadecimal) as the filename for the individual customer database.

The total addressable market for my application is about 2,500 customers, and they won't use it at all in most weeks. I'm aware that this usage pattern is very uncommon, so I don't recommend what I'm doing as a general solution.

Re:Siren Call of SQLite on the Server by timcobb on Tuesday February 18, 2025 @07:49AM (#43088885)
> The total addressable market for my application is about 2,500 customers, and they won't use it at all in most weeks. I'm aware that this usage pattern is very uncommon

Is it even?

Re:Siren Call of SQLite on the Server by jmull on Tuesday February 18, 2025 @08:53AM (#43089463)
I'm with you on this. I think this is a widely desirable pattern. If it's uncommon it's because of how poorly traditional dbms's address it.

I suspect as server-side sqlite matures, this pattern will explode in popularity.

Re:Siren Call of SQLite on the Server by vidarh on Wednesday February 19, 2025 @05:23AM (#43100585)
I've done pretty much that, but without SQLite as the origin of that system predated SQLites first release, with millions of users. It works, and it scales. Since then I've increasingly preferred this pattern when it's been suitable, and as SQLite has grown in maturity, it increasingly is suitable.