3 ms·
> then what's the reason people aren't using it for websites? I'd guess the reason to be that people keep hearing things like "don't use SQLite for websites" a
by yellowapple 6y ago
> then what's the reason people aren't using it for websites?
I'd guess the reason to be that people keep hearing things like "don't use SQLite for websites" and thus don't even try.
> Why do you say it works for "small" websites but presumably not large ones?
Not the GP, but the main reason I wouldn't use SQLite for a large website is that SQLite itself doesn't offer much re: failover/replication (i.e. multiple servers, one database), and I haven't used RQLite enough (or at all; I should fix that) to be comfortable with it in production. Because of that, I'm more likely to reach for / recommend PostgreSQL instead.
That being said, if your website has crazy "web scale" FAANGesque needs and you're at the point where you need to write your own replicated datastore, using SQLite as a base and building your own replication layer on top of it (or using RQLite and maybe adjusting it for your needs) seems like a reasonable way to go.
- pbowyer 6y ago> That being said, if your website has crazy "web scale" FAANGesque needs and you're at the point where you need to write your own replicated datastore, using SQLite as a base and building your own replication layer on top of it (or using RQLite and maybe adjusting it for your needs) seems like a reasonable way to go. Exactly what Bloomberg did with Comdb2: https://github.com/bloomberg/comdb2 https://github.com/bloomberg/comdb2
- benbjohnson 6y agoI'm in the process of adding read replication to Litestream[1] so folks can scale out the read-side of their SQLite applications to multiple nodes (or replicate to edge nodes for low-latency). [1]: https://litestream.io/ https://litestream.io/
- pdimitar 6y agoAmazing. This was missing for my use-case and I gave up on LiteStream because of it but now it seems I have to revisit! Wonderful job.
- yellowapple 6y agoNeat. I'll have to give that a whirl. Would this enable any node to be a writer (i.e. would it lock the DB across all nodes)? Or would I have to designate some "master" server with exclusive write access and have any other servers forward write requests to that server?
- benbjohnson 6y agoIt would be the latter. You'd need to have a single primary and replicas would need to redirect writes to that node.
- gm3dmo 6y agoCrazy web scale folks flip from Mongo (NoSQL) to Postgres: https://www.theguardian.com/info/2018/nov/30/bye-bye-mongo-hello-postgres https://www.theguardian.com/info/2018/nov/30/bye-bye-mongo-h...
- anonymousiam 6y agoGreat article. It took them 10 months to successfully migrate! No mention of how many man-hours, but probably a lot.