Hacker News new | ask | show | jobs
by sgeisenh 725 days ago
In the pseudocode snippet that introduces a WAL, the semaphores are signaled before the fsync occurs. This seems like a mistake but maybe there’s a good reason to do this that I am missing?

Edit: it looks like this is the case in the first batched fsync example, as well.

1 comments

Good catch! That was a think-o. I've swapped it around so that semaphores are signalled after the fsync.
Thanks for the quick response, and for the nice write up. I thoroughly enjoy the python-like pseudocode, it was the main reason I was able to pick that out reasonably quickly!