On 19 November 2010 12:09, Clifford Heath <[email protected]> wrote:
> On 19/11/2010, at 11:27 AM, Dmytrii Nagirniak wrote: > >> But as far as I understand Chris needs to ensure that there are no stale >> objects in the middle of an action (not user's one but a system's). >> > > That's not even theoretically possible in a parallel system. I guess we are talking about different things here. But I believe we all agree that you cannot guarantee consistency without locking. The database transaction with serialisable isolation level does provide locking, thus removes parallelism. So that user2 has to wait until user1 would have finished the transaction, even to read data. As a result we can say that using transactions it is possible to achieve atomicity, isolation and non-stale data within that transaction. I guess, this is how most payments are being done. -- You received this message because you are subscribed to the Google Groups "Ruby or Rails Oceania" 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/rails-oceania?hl=en.
