Hi,
I am writing a B4A app that will be using 2 background services (both 'StartAtBoot' BTW).
Both services access the same storage file (keyvaluestore). One will be putting data in the storage and 1 will be removing from the storage.
Will both services run in their own thread and to be thread-safe should I access the keyvalue store in a callsubdelayed ?
Or should I use AGraham's threading library and use a semaphore to
- open the keyvaluestore file
- add or remove data
- save the keyvalue store file ?
Thanks
I am writing a B4A app that will be using 2 background services (both 'StartAtBoot' BTW).
Both services access the same storage file (keyvaluestore). One will be putting data in the storage and 1 will be removing from the storage.
Will both services run in their own thread and to be thread-safe should I access the keyvalue store in a callsubdelayed ?
Or should I use AGraham's threading library and use a semaphore to
- open the keyvaluestore file
- add or remove data
- save the keyvalue store file ?
Thanks