On May 25, 2011, at 11:19 AM, Pawel R wrote: >> Synchronise what with what? > > Synchronize with other threads. I need this method to be invoked by only one > thread at a time. > >> "It doesn't work" is utterly useless. What does it do? > > It lets more than 1 thread to invoke this method at a time. > >> How does that differ from what you were expecting? > > I want only one thread to access this method.
I would push the atomic updates to the database or use a queue with a single worker. Thread level locking doesn't scale across processes or servers. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.