Object version numbers

Derek Atkins warlord@MIT.EDU
07 Mar 2001 20:40:57 -0500


When do version numbers get incremented?  Is it the role of the
engine?  Or is it the role of the Backend?  Does it happen when the
object is stored, or when the object is opened for edit?  Also, in a
multi-user semi-offline system, I think there is still a problem
detecting when the version is changed.

I'm trying to figure out version-number sematics for the RPC backend,
but I'm not at all sure how to increment, or when.

Looking at the Postgres backend, there are places where it looks like
the version number is incremented multiple times.  For example,
following the flow of commit_edit(), you increment the version number
in the commit_edit() function, but then again in storeAccountNoLock().
So, you wind up incrementing the version twice.  Is this a bug, or is
it on purpose?

I can't find any documentation describing how the version number
should be used, or who controls it.

-derek

-- 
       Derek Atkins, SB '93 MIT EE, SM '95 MIT Media Laboratory
       Member, MIT Student Information Processing Board  (SIPB)
       URL: http://web.mit.edu/warlord/    PP-ASEL-IA     N1NWH
       warlord@MIT.EDU                        PGP key available