On 17.10.2013 12:31, Patrick Ohly wrote:
For example, exclusive write access to the sqlite DB in EDS or the Tizen contacts service simplifies change notification, because a single process knows what changes are made at a semantic level and can send change notifications to readers more efficiently. With shared write access, all a reader can get from the OS is "file modified".
You can have an auxiliary notification queue with sqlite or you could use postgresql and it's NOTIFY/LISTEN.
There's also nothing that prevents multithreading in such a design. I don't see how you came to that conclusion. EDS is internally multithreaded and allows concurrent reads directly from the sqlite file (only writing is centralized).
There's a write bottleneck, because with record-locking you could simultaneously write to different portions of file without conflicts. But unfortunately sqlite doesn't support that, so it needs some more advanced database.
When you expand this, or read/write locking (for multi-reader, single-writer) outside of the process you already solved the problem.
_______________________________________________ Dev mailing list [email protected] https://lists.tizen.org/listinfo/dev
