durusmail: durus-users: Does durus support rollbacks?
Does durus support rollbacks?
2007-04-27
2007-04-27
2007-04-27
2007-04-28
2007-04-28
2007-04-28
Does durus support rollbacks?
Terry Hancock
2007-04-27
David Binger wrote:
> I think you are talking about the ZODB feature called versioning,
> which I understand to be deprecated and faulty (but nevertheless
> cool to see working in a Zope application).

I don't think so. I just want a simple 'undo'/'redo'. Branching (for my
application) can be achieved by copying the whole storage file (or by
creating a copy within the database, as you later suggested).

> Durus does have a HistoryConnection
> implementation that is intended as a diagnostic tool for peeking
> into earlier transactions.  You might find that interesting.

Okay, I'll look for that.

>> If it can't do it, how hard would it be to add, do you think? Is it
>> something I could bolt on by sub-classing connection? Does the storage
>> model support the kind of rollback I'm talking about?
>
> That would be a difficult path to take, but not impossible.
> Durus does not maintain transaction timestamps or version
> numbers, so one challenge would be to determine which
> transaction you really want.

Not a problem. The user would pick "save points", and the game would
just save the current transaction number. All I need is the ability to
recover the state at that transaction number (it's okay if I have to
throw away later changes).

So, if I know exactly which transaction I want, is it relatively easy
from there? Can I just throw away all the later changes and recover the
state at that transaction? (And, of course, how?)

Thanks for
Terry

--
Terry Hancock (hancock@AnansiSpaceworks.com)
Anansi Spaceworks http://www.AnansiSpaceworks.com

reply