4 ms·
On Task Systems
- roskilli 14y agoLooks similar to what Kue http://learnboost.github.com/kue/ http://learnboost.github.com/kue/ already does. I wish node had less fragmentation and more consolidation on these types of libraries/frameworks. Nice article breaking down the features and patterns of queue/task engines if nothing else!
- evantahler 14y agoCool! I haven't heard of Kue. I'll take a look! Source for the curious: https://github.com/learnboost/kue https://github.com/learnboost/kue
- nolliesnom 14y agoThe article's statement "Putting them within a transaction is also no good, as you can't read and make decisions on the result (is the result of the select null?)" is not correct. You can implement task assignment in a SERIALIZABLE-capable RDBMS using a single "UPDATE ... SET assigned_to = 'me' WHERE assigned_to IS NULL" statement, or the equivalent of "SELECT FOR UPDATE" at the beginning of a transaction in order to examine the row in advance.
- evantahler 14y agogood call, I'll update that. I generally assume mySQL's feature-set, which I probably shouldn't do without clarification.
- SeoxyS 14y agoIn my experience, I've found that it is much more reliable to use message queues instead of databases as the backing for job scheduling. Learning a complex but powerful MQ like Rabbit can be a little bit of a chore, but it more than pays off in the long run.