company logo

Versioning Levels

Versioning levels allow enabling simple or hierarchical (managed) versioning. Simple versioning cannot be defined explicitly, but any versioning mode that not include the managed feature is assumed to support simple versioning. When changing the versioning mode, one may change from managed to simple versioning mode, but not reverse.

Sometimes, the state of a complete database needs to be preserved in order to access earlier versions of the data (e.g. for supporting schema versions). A comfortable way of achieving consistent database versioning is managed versioning.

Managed database versioning supports two version levels:

  • Major version - Major versions are created on database level. Major versions are versions associated with a timestamp indicating the begin of the version interval for a version. The maximum number of major versions is 65535.
  • Minor versions - minor versions are not associated with a time stamp, but may be associated with time stamps by the application. Within a major version, up to 65536 minor versions may be created. In this case, the version number is the combination of major version and minor version:

version number = (major version * 65536) + minor version

Managed versioning is based on defining major versions for the database on demand or in advance. Major versions are associated with a time interval defining the version validity. Within a time interval for a major version, all modifications of database entries (instances, indexes) are treated as "updates". Starting a new major version, new database entry versions are created automatically, whenever an older database entry (database entry with lower version number) is modified (copy on write). The version interval can be a fixed interval (e.g. each hour, weekly or monthly, yearly) or a variable interval explicitly defined by the database administrator.

Major versions form an allover sequence of time intervals with an open start and an open end interval. The version interval for a major version may be changed by updating the starting time point or the starting time point for the next major version, as long as the version interval is defined in future. ODABA supports up to 65535 major versions for a database (e.g. beginning a new version each day, major versions for 180 years could be created for a database).

Major versions may be combined with owner scope versions, which allow creating up to 65536 minor versions for each major version.

Subtopics

  1. Simple versioning
  2. VM_managed - Managed versioning