Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-25298

Refuse to use a database migrated by a more recent version of XWiki

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Major
    • None
    • 18.8.0
    • Old Core
    • Unknown

    Description

      XWiki refuses to use a database which needs a migration, but nothing stops an older version of XWiki from using a database migrated by a more recent version: after a downgrade, a rollback of a deployment, or when a cluster member still running the previous version starts after another member migrated the database. With migrations enabled the older version even runs its Hibernate schema update on it, which can bring back what the newer version changed, and it reads and writes data that may be in a format it does not know.
      Proposal: refuse a wiki database whose version is higher than the latest data migration version known by the running XWiki, with an error explaining that it was migrated by a more recent version and that a downgrade requires a new installation and a XAR import. The existing xwiki.store.migration.version property of xwiki.cfg forces the version and thus allows using such a database at one's own risk. Note: data migrations provided by installed extensions count too, so the cluster members need the same extensions.

      Attachments

        Issue Links

          Activity

            People

              ciaens Clément Christiaens
              ciaens Clément Christiaens
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated: