On 19 May 2009, at 09:56, [email protected] wrote:
>
> As you understand if we have multiple concurrent requests for #start,
> there is a possibility of a race condition, where two or more
> processes are running the if branch.
>
> I want the #start request to be atomic, meaning that only one of the
> concurrent processes can actually execute the if branch, others must
> be waiting or get some kind of error.
>
> Should the request be somehow wrapped into a DB transaction?
>
take a look at optimistic locking.

Fred
> -Kirill
> >


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to