MigratorPageProvider is a WikiPageProvider for migrating pages from one provider to a new provider. MigratorAttProvider does the same for attachments. Source code(info) and jar file(info) are provided as attachments to this page.

These providers work by getting all the pages from the old (source) provider and adding them all to the new (destination) provider. The migration is triggered only if the new provider has no pages. After that, these providers just act as proxies for the new provider and can be removed from the configuration.

After placing the attached migrator.jar(info) file in the WEB-INF/lib directory, the following configuration is necessary in the jspwiki properties file.

 jspwiki.pageProvider = com.forthgo.jspwiki.migration.MigratorPageProvider
 jspwiki.migration.fromPageProvider = (source page provider class name)
 (other properties for source provider)
 jspwiki.migration.toPageProvider = (destination page provider class name)
 (other properties for destination provider)

The attachment migrator's settings:

 jspwiki.attachmentProvider = com.forthgo.jspwiki.migration.MigratorAttProvider
 jspwiki.migration.fromAttProvider = (source attachment provider class name)
 (other properties for source provider)
 jspwiki.migration.toAttProvider = (destination attachment provider class name)
 (other properties for destination provider)

These two providers can be used independently.

Start-up time for the wiki will be longer than usual since that is when the migration happens.

Short-comings#

  • While version histories are preserved (if supported by the real providers), modification dates are lost. This is because when a provider is given a new page to add, it ignores the provided modification date and uses the current date/time.
  • The two real providers (old and new) must be able to have their configuration properties co-exist in the same properties file.

Add new attachment

Only authorized users are allowed to upload new attachments.

List of attachments

Kind Attachment Name Size Version Date Modified Author Change note
jar
migrator.jar 6.2 kB 1 13-Aug-2005 23:58 Daggerbox
zip
migrator_src.zip 8.2 kB 1 13-Aug-2005 23:58 Daggerbox
« This page (revision-1) was last changed on 02-Sep-2005 13:23 by Daggerbox