Data Versioning
This guide takes you through how we track changes to all elements in OpenDataDSL and how you can take advantage of multiple versions and follow an audit trail of every change made.
Introduction
One of the most important aspects of data management is tracking changes that have been made to every aspect of the system. Some of the ways you can utilise this are as follows:
Tracing issues
When things stop working or start producing incorrect results, you need to be able to trace through everything that has changed in order to resolve the issue.
Utilise tagging to ensure stability
If you tag versions with names, e.g. PROD, you can implement a phased approach of releasing new versions of elements into the system. There is a dynamic tag (~LATEST) which always points to the last or current version.
How it works
Types of versioning
There are 2 types of versioning: automatic and user-defined.
Automatic versioning
Automatic versioning is always-on which means that any change to the element results in a new version. The following elements have automatic versioning:
- Actions
- Calendars
- Extractors
- Report configurations
- Reports
- Scripts
- Transformers
- Types
- Workflows
User defined
For objects, you have the choice, per type, of whether to use versioning or not. When you create a type, you can specify that all objects of that type are versioned by using the versioned modifier:
Widget = versioned type
name as String()
price as Number()
end
If you save an object using the above Widget type, the system checks for an existing object of the same id and if it is different, it saves it as a new version.
What is recorded
Along with the actual data, a version property is added with the following attributes:
Name | Description | Type |
---|---|---|
version | The version number which is an incremental number, starting at 1 | Integer |
oid | The id of the object | String |
timestamp | The date/time that the update was made | Date |
user | The email address of the user who made the change or the tenantid if it was updated via a process | String |
tag | A list of tags that you can add to a version | List |