Sure thing. I am writing an OPDS client app and ebook manager. It's 
designed to query public domain OPDS book catalogs 
(e.g., http://www.feedbooks.com/catalog) and to help manage an ebook 
collection. I have, for example, a feature that allows one to rename and 
reorganize a book collection on disk. It is a long running process with a 
larger book collection, so I am using the scheduler to run the task. Once 
the task is completed, I want to display a flash notification in the UI 
notifying the user that it is complete. Mind you, there are other 
background tasks as well (some on a regular schedule) that will also be 
running at times that I also would like to have UI notifications for.

>From my understanding, one can use the database or the file system to 
communicate the message to the UI. Or one could use websockets. I had 
thought the easiest way would be to have a small table in a possiibly 
separate database to store the message. The UI could then occasionally poll 
the server for new messages, display it as a flash message and delete it 
from the database. But since I will be using sqlite as the database, I was 
concerned about concurrency since I would have two different processes 
possible accessing the database at the same time.

So I was looking for some advice on how best to proceed. 

Thanks
Rod

On Sunday, October 11, 2015 at 9:50:02 AM UTC-7, Massimo Di Pierro wrote:
>
> Can you tell us more about the use case?
>
> On Friday, 9 October 2015 22:51:04 UTC-5, Rod Watkins wrote:
>>
>> Hi everyone,
>>
>> I have a question about the scheduler and communicating between the 
>> scheduler process and my web app. In another post here, Niphlod suggested 
>> using the database or the file system to communicate between the scheduler 
>> and my app--for example, to communicate some content to display in a flash 
>> message. I will be using sqlite as my database. What are the concurrency 
>> problems I may be facing sharing the message through sqlite? Would using 
>> the file system be better? Or, should I consider a more sophisticated 
>> messaging system like that in websocket_messaging in the contrib folder. Or 
>> is there some other better way?
>>
>> Thanks
>> Rod
>>
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to