News for hackers. Stuff that matters.
Re:Why you should probably be using SQLite by loloquwowndueo on Friday October 27, 2023 @02:47PM (#38042349)
Point Postgres data directory to a memory-backed tmpfs, makes the thing blazing fast.
Re:Why you should probably be using SQLite by paulryanrogers on Friday October 27, 2023 @11:30PM (#38046860)
I've done this for MySQL too. Saved our CI times on GitHub Actions after upgrading to MySQL 8 and the single threaded performance dropped.
Re:Why you should probably be using SQLite by sa46 on Friday October 27, 2023 @11:53PM (#38046983)
I've tried--macOS doesn't make it easy. It's not a clear performance win since tmpfs with Postgres fsync=off is mostly memory-backed storage via the page cache already.

Another problem is that parallel tests can exhaust memory.

The slowest part of our tests is syscall overhead. A mostly empty Postgres data dir for a medium-sized database with a few hundred tables consists of 3k files. On my M1 macOS, it takes 120 ms to delete the entire data dir. Copying is cheaper at 80 ms using clonefile.