News for hackers. Stuff that matters.
Re:Why SQLite is so great for the edge by bob1029 on Tuesday June 06, 2023 @08:06AM (#36211397)
I've done the SQLite benchmark a few times. You can insert somewhere in the range of 10~20k rows per second if you are using NVMe (i.e. ~50uS per row). Requires some pragmas (i.e. WAL). This is 100% serialized throughput.

No clue what Postgres would manage, but I suspect it would be about an order of magnitude higher latency in the happy case.

Re:Why SQLite is so great for the edge by runeks on Tuesday June 06, 2023 @02:20PM (#36216982)
> No clue what Postgres would manage, but I suspect it would be about an order of magnitude higher latency in the happy case.

Unless you’re talking 1 versus 10 microseconds (or less), I don’t think Postgres will have an order of magnitude higher latency. And if we are talking this range, why would it matter for a web app where the client’s latency is almost certainly >1 millisecond?

Re:Why SQLite is so great for the edge by ripley12 on Monday June 12, 2023 @08:11PM (#36303275)
Because it changes the kinds of things you can build: https://www.sqlite.org/np1queryprob.html

With SQLite, it's often practical to issue several queries in situations where that would be too slow for a traditional client-server database.

Re:Why SQLite is so great for the edge by norir on Tuesday June 06, 2023 @02:46PM (#36217314)
I'm pretty sure sqlite is capable of significantly higher throughput that 10-20k rows per second depending on the workload. Inserts can be much faster if they are batched in large transactions and prepared statements are used to avoid sql parsing for each row. This only works of course if your workload can be batched.