@caekislove You can pass a DATABASE_URL now and choose sqlite://db.sqlite3 or postgres://localhost:5432/ditto and decide for yourself how you'd prefer to suffer.
@caekislove The main problem with SQLite is 10 minute long queries that should take 0.01s. Re-running the exact same query again takes 0.01s. This is in a 40GB database. Then I found a 20 year old thread of people complaining about how SQLite relies on OS disk cache and it can do that sometimes.
My original idea was to prune the db so it's always small, keeping only the last 7 days of data. But the other problem with SQLite is that it destroys performance to delete things! So whenever you run that cron it freezes the whole application for all users.
It could probably have been improved by running a worker pool on top of it. But you would still get 10 minute queries in some threads, it just wouldn't block the others.
@caekislove I think it could be, but you have to do a lot of engineering around it. You'd have to manage many smaller SQLite files and then route requests to it.
Add comment