On Mon, Nov 14, 2011 at 09:14:00AM -0800, Nathan Stults wrote: > > John, thank you for all the pointers. Today we will set up a test > environment to take measurements and apply some realistic loads and take > a closer look at all the points you mentioned. One question on the > schedules - if the behavior of a worker is to pull all schedules and > fire triggered ones, how does this work in a multi-worker environment? > Is that what "reserve" is used for in the storage? (We haven't > implemented reserve in MongoDB, but probably should)
Hello, yes Storage#reserve(doc) is meant to return true if the worker has successfully reserved the document for its own use. It's very important for multi-worker storages to implement this method correctly. If it returns true twice for the same doc (msg or schedule) you'll end up with a workflow operation being performed twice (branches popping out of nowhere) and schedules triggering twice. Maybe simply fixing #get_schedules will yield sufficient gain so that you can stick with one worker. We'll see. Best regards, -- John Mettraux - http://lambda.io/processi -- you received this message because you are subscribed to the "ruote users" group. to post : send email to [email protected] to unsubscribe : send email to [email protected] more options : http://groups.google.com/group/openwferu-users?hl=en
