[Zope] zope operations atomic?

Clark OBrien COBrien@isis-server.vuse.vanderbilt.edu
Wed, 31 Oct 2001 13:25:36 -0600


I don't want to be dense but it sounds like for each thread a deep
copy of the items it accesses- Folder for example- is made. When session
ends or something triggers a commit a check is made for conflicts.

This sounds a bit scarry because if you have a script changing resources
like a Folders
it is almost certain then that there will be a conflict. At this point a
retry still
find conflicts. I would rather have heard the Folder was a critical
section or methods
like manage_changeProperties were atomic. IMHOP it should be so.


 

-----Original Message-----
From: kapil thangavelu [mailto:kthangavelu@earthlink.net]
Sent: Wednesday, October 31, 2001 3:03 AM
To: Clark OBrien; 'zope@zope.org'
Subject: Re: [Zope] zope operations atomic?


On Wednesday 31 October 2001 07:11 am, Clark OBrien wrote:
> Hi:
> I cannot find documentation that would tell me how zope manages thread
> synchronization

nutshell version.

zope uses optimistic conflict resolution, no application level locking
takes 
place, because all threads have their own object spaces. only on
commits, is 
there some synchronization (deep within the zodb) to insure that there 
weren't conflicts, if so a conflict error is raised, and the request
gets 
retried. applications can define their own conflict resolution, see the
zodb 
wikis and zope developer's guide for more details.

kapil