• Jim Fulton's avatar
    Refactored FileStorage transactional undo · d717a685
    Jim Fulton authored
    As part of a project to provide object-level commit locks for ZEO, I'm
    refactiring FileStorage to maintain transaction-specific data in
    Tranaction.data.  This involved undo.  In trying to figure this out, I
    found:
    
    - A bug in _undoDataInfo, which I verified with some tests and
    
    - _transactionalUndoRecord was maddeningly difficult to reason about
      (and thus change).
    
    I was concerned less by the bug than my inability to know whether a
    change to the code would be correct.
    
    So I refactored the code, mainly transactionalUndoRecord, to make the
    code easier to understand, fixing some logic errors (I'm pretty sure)
    along the way.  This included lots of comments. (Comments are much
    easier to compose when you're working out logic you didn't
    understand.)
    
    In addition to makeing the code cleaner, it allows undo to be handled
    in cases that weren't handled before.
    d717a685
Name
Last commit
Last update
doc Loading commit data...
src/ZODB Loading commit data...
.coveragerc Loading commit data...
.gitignore Loading commit data...
.travis.yml Loading commit data...
3.11.txt Loading commit data...
CHANGES.rst Loading commit data...
COPYING Loading commit data...
COPYRIGHT.txt Loading commit data...
HISTORY.txt Loading commit data...
LICENSE.txt Loading commit data...
MANIFEST.in Loading commit data...
README.rst Loading commit data...
bootstrap.py Loading commit data...
buildout.cfg Loading commit data...
ez_setup.py Loading commit data...
log.ini Loading commit data...
release.py Loading commit data...
setup.py Loading commit data...
tox.ini Loading commit data...