I'm currently writing a VFS for Node, and I see that xCheckReservedLock and xSleep are basically no-ops in vfs.c, so I can't quite implement them in vfs.js.
I think it would be better to expose these at the vfs.js level, and making them no-ops there instead.
The idea is that in some scenarios they could be implemented (with Atomics.wait for example, or a native node module), and implementing them to my understanding could be beneficial (if a file is locked already then I think sqlite will sleep for a bit and check again, which seems better than always blocking when trying to get a lock).
I'm currently writing a VFS for Node, and I see that
xCheckReservedLock
andxSleep
are basically no-ops invfs.c
, so I can't quite implement them invfs.js
.I think it would be better to expose these at the
vfs.js
level, and making them no-ops there instead.The idea is that in some scenarios they could be implemented (with
Atomics.wait
for example, or a native node module), and implementing them to my understanding could be beneficial (if a file is locked already then I think sqlite will sleep for a bit and check again, which seems better than always blocking when trying to get a lock).