[izpack-devel] Backup for the installed files and the wipeAbort problem

Michael Scherer michi at buks-island.org
Mon Aug 21 09:09:56 CEST 2006


Good morning all.

As you might know (or not) I had some issues two weeks ago cause an installer 
erased all files of an application after we canceled it right after the 
InstallationPanel.
I know that this is no "real" problem cause IzPack is more an installer than 
an updater but we use it here for both purposes.

First of all I disabled the wipeAbort() function for our installer to make 
sure that won't happen again. That's not the ideal solution, I know, but makes 
sure that at least the configs remain where they belong. I'll come back to the 
wipeAbort() function later.

Second we decided that I'd be nice to have some sort of "backup" in IzPack.
If not during the installation process, than at least in the Uninstaller.
What I implemented now is a backup class, that gets the filenames of the files 
that are installed before they are copied to the filesystem and adds them, if 
enabled with
  <uninstaller write="yes" backup="yes" .../>
to the subdirectory "backup" of the Uninstaller.jar
On a local filesystem that doesn't really takes much time.

The Uninstaller(Frame) got extended that if the "backup" subdirectory exists 
it allows the user to roll back that one installation.
So if you installed the wrong update into the wrong directory ... simply roll 
it back with the Uninstaller.

Question 1: Do the IzPack-Devs like that idea?
Question 2: If so, where to send the patches? :)

Now back to the wipeAbort() function.
With the backup-info/data in hand the wipeAbort function might also rollback 
the previously done steps instead of erasing the whole directory tree.
Which is IMHO a bit of an awkward approach anyway.

Ideas? Opinions? Flames? :)

Greetings,
  Michael




More information about the izpack-devel mailing list