Class XWikiDBVersion

  • All Implemented Interfaces:

    public class XWikiDBVersion
    extends Object
    implements Comparable<XWikiDBVersion>
    Stores XWiki's data version in the database. Used to find out which migrations to execute based on the current data version in the Database (each migration says which minimal version it requires to execute).

    The version scheme in the past was to use the SVN revision number of the commit of the migrator but since we've now moved to Git we're now using an integer matching the current XWiki version and allowing for a range of 1000 migrations. So if you're writing the first migrator for version 5.2 of XWiki then the version will be 52000. If you're writing the 2nd migration for XWiki 5.2 then its version would be 52001, etc.

    $Id: f7d837eee58ca94c8e3f0888aa71fddda058689c $
    • Constructor Detail

      • XWikiDBVersion

        public XWikiDBVersion()
        Default constructor. It is need for Hibernate.
      • XWikiDBVersion

        public XWikiDBVersion​(int version)
        version - - data version