3 ms·
So does that mean serving static files from a SQLite file would be faster than something like NGINX?
by devmunchies 8y ago
So does that mean serving static files from a SQLite file would be faster than something like NGINX?
- oscargrouch 8y agoNo, because of the sendfile syscall, where the kernel pass all the file data without switching back to userspace. Even if you can in theory save some time with small files with sqlite, you would be back to read/write IO and userspace/kernel byte buffer switching. And it probably wouldn't be faster than something like a mmaped file anyway (unless the SQLite Db is also mmaped).
- fiddlerwoaroof 8y agoThe thing is SQLite handles a lot of hard problems that you might not realize you have: like “was my data actually written to the disk”