[e-lang] Alternative persistence system
Thomas Leonard
tal at it-innovation.soton.ac.uk
Thu Jan 14 09:05:52 PST 2010
On Mon, 2009-10-12 at 10:58 +0100, Thomas Leonard wrote:
> Summary
>
> I've spent some time using the E persistence mechanism now, and I've
> found it to be clever, elegant and very hard to use for my purposes. I
> ended up writing my own replacement for the timeMachine and
> makeSturdyRef objects. Below is a report on the problems I had and the
> solution I ended up with. Has anyone else had similar issues?
[...]
I now have my new system saving the state in an SQL database (currently
testing using hsqldb). I've put a write-up here:
http://labs.it-innovation.soton.ac.uk/index.php?option=com_content&view=article&id=70:database-backed-persistence-in-e&catid=36:experiments
The code is rather messy at the moment, but it is available from the
page if you want it and it might make it clearer what we're trying to
do.
Using the database makes the system somewhat slower overall, but the
slowness is spread out, rather than having the system stop for long
periods while saving. This makes the GUI experience rather more
pleasant.
Note that if you only want occasional snapshots (as with traditional E)
then it's quite simple to "flush" the hsqldb connection and copy the
database files, and this is much faster than doing snapshots with E's
timeMachine.
Comments?
--
Dr Thomas Leonard
IT Innovation Centre
2 Venture Road
Southampton
Hampshire SO16 7NP
Tel: +44 0 23 8076 0834
Fax: +44 0 23 8076 0833
mailto:tal at it-innovation.soton.ac.uk
http://www.it-innovation.soton.ac.uk
More information about the e-lang
mailing list