[ZODB-Dev] Eek!

Chris Withers chrisw@nipltd.com
Tue, 09 Oct 2001 17:23:35 +0100


Jim Fulton wrote:
> 
> > Huh? Sorry, lost me after the comma there...
> 
> I don't think it would be a shocking oversight if FileStorage
> wasted some disk space for aborted transactions if they were
> cleaned up with a pack.

I would agree, so long as packing wasn't a manual process, which it is :-S
Do any of the BDB storages not need packing and yet still keep a specified
amount of object history?

> Further, the bug should not cause the transaction to be left.
> If Zope were restarted before any other transactions were written,
> it would truncate the bad data on startup.
> 
> Otherwise, subsequent transactions will overwrite the aborted
> transactions, because the file position hasn't been advanced
> past the bad transaction.

Hmmm, well, I'm not disagreeing but that hasn't been my experience. I dunno if
it makes a difference, but this isn't 'Zope' as such, it's a Storage server with
one Zope client and another that's a glorified version of:

import Zope
app = Zope.app()

for x in y:
  try:
    get_transaction().begin()
    ...do stuff...
  except:
    get_transaction().abort()
  else:
    get_transaction().commit()

> for fixing the bug, I realized that my initial analysis of the situation was
> incorrect. Sorry for the false alarm.

*phew* :-)

cheers,

Chris