Hello,<br><br>As a certified newbie, I have a few questions on how to properly handle a situation where multiple users may want to perform the same worker task at the same time, but with different arguments.<br><br>Initially I opted towards making many very specific workers to have a situation where it was highly unlikely that any two users would be asking the same exact worker to do something.&nbsp; Now I&#39;m trying to consolidate everything into as few workers as possible to conserve memory (I think?).&nbsp; What it&#39;s come down to at this point is that I have 2 workers whose methods are scheduled in config/backgroundrb.yml.&nbsp; And one worker whose methods are not scheduled and are intended to be called through user initiated actions.<br>
<br>My question is then - how should I go about handling the case where user1 has asked the user_worker to do_something at the same time user2 has asked user_worker to do_something or do_something_else.<br><br>What happens when backgroundrb receives a worker request on a worker that is half way through a method from a previous request?<br>
<br>Is there a way to ask a worker something along the lines of &quot;are you busy with another user&#39;s request right now?&quot;.<br><br>I&#39;m trying not to spawn unique workers as I&#39;m not sure how best to get rid of them.&nbsp; Would it make sense to create a new worker for the specific task, run the task, and kill the worker if the user may want to run the task fairly frequently?<br>
<br>- Steve<br><br><br>