However there are quite a few members who are developing read caches to improve performance.
If you do decide to write at the time the user does the booking, you are only writing a very small amount of data, so this is not likely to cause you a performance problem.
How is a read cache different from deferred write? What are its implications?
You're probably right. But still, at that very moment all other threads that would like to have access to the data - read or write - have to wait until the semaphore has been released.
If I got that right (looking at it from the users perspective), the GUI freezes until any alteration to the data the user submitted has been written into the file.
Of course any alteration could still be carried out through an individual thread, but then the same problems (how to report back errors, successful booking has already been indicated) arise.
I think any client operation (not just update operations) should be run in an individual thread
Weeds: because mother nature refuses to be your personal bitch. But this tiny ad is willing:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koophttps://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton