| ▲ | daitangio 9 hours ago | ||||||||||||||||||||||||||||||||||||||||
I am using SQLite on paperless-ngx (an app to manage pdf [4]). It is quite difficult to beat SQLite if you do not have a very huge parallelism factor in writes. SQLite is an embedded database: no socket to open, you directly access to it via file system. If you do not plan to use BigData with high number of writers, you will have an hard time beating SQLite on modern hardware, on average use cases. I have written a super simple search engine [1] using python asyncio and SQLite is not the bottleneck so far. If you are hitting the SQLite limit, I have an happy news: PostgreSQL upgrade will be enough for a lot of use cases [2]: you can use it to play with a schemaless mongo-like database, a simple queue system [3] or a search engine with stemming. After a while you can decide if you need a specialized component (i.e. Kafka, Elastic Search, etc) for one of your services. [1]: https://github.com/daitangio/find [2]: https://gioorgi.com/2025/postgres-all/ | |||||||||||||||||||||||||||||||||||||||||
| ▲ | CuriouslyC 6 hours ago | parent | next [-] | ||||||||||||||||||||||||||||||||||||||||
The pattern I like to advocate for now is to do customer sharding with SQLite. Cloudflare makes this easy with D1, you can tie Durable Objects to a user as an afterthought. The nice thing about this pattern is that you can create foreign data wrappers for your customer SQLite databases and query them as if they were in postgres, cross customer aggregations are slow but individual customer analytics are quite fast, and this gives you near infinite scalability. | |||||||||||||||||||||||||||||||||||||||||
| ▲ | storystarling 6 hours ago | parent | prev [-] | ||||||||||||||||||||||||||||||||||||||||
You hit those write limits surprisingly early if you use background workers though. I had a project with very little user traffic that choked on SQLite simply because a few Celery workers were updating job statuses concurrently. It wasn't the volume of data, just the contention from the workers that forced the switch to Postgres. | |||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||