Brian wrote:
> This is a two part question.  Which type of locking should I use
> (optimistic vs. pessimistic) and then how do I account for locking in
> my tests?
> 
> My scenario is essentially the purchase of a unique item where the
> first person to click "Buy" gets the item
[...]

I doubt that you need explicit locking.  Skilful use of transactions 
should do the trick and be much easier to manage.

Best,
--
Marnen Laibow-Koser
http://www.marnen.org
mar...@marnen.org
-- 
Posted via http://www.ruby-forum.com/.

--~--~---------~--~----~------------~-------~--~----~
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 rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to