[Koha-bugs] [Bug 30172] Background jobs failing due to race condition

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Thu Mar 24 01:05:51 CET 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30172

--- Comment #14 from David Cook <dcook at prosentient.com.au> ---
(In reply to Tomás Cohen Arazi from comment #13)
> We have a daemon that runs in two ways: listening to the STOMP protocol, or
> just polling the DB...
> 
> And we have a task initiator (i.e. a call to ->enqueue) that needs to decide
> if it does through the STOMP protocol or just inserts on the DB...

Could you re-phrase this? I'm not sure what you're saying here.

Ultimately, the database acts as a result store. The message broker passes the
message from the web app to a background worker. The background worker
processes the message and updates the result store. The web app exposes the
result store to web users.

The same model is used by other task queues like Celery
(https://github.com/celery/celery) and Minion (https://metacpan.org/pod/Minion
->
https://metacpan.org/release/SRI/Minion-10.23/source/lib/Minion/Backend/Pg.pm#L35). 

While Celery uses message brokers, Minion does poll the database.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list