Versioning
Dubnium has 2 options to save Record versions.
Last updated
Was this helpful?
Dubnium has 2 options to save Record versions.
Last updated
Was this helpful?
Save versions to db.versions.temp
. Temporary versions are removed when the process starts. This can be enabled when initializing Dubnium.
Create a new file in .dubnium/versions/{tag_here}
. This can be enabled when initializing Dubnium.
The files are stored in .dubnium/versions/TAG/DATE
and the file contents are identical to the Record.
When initializing, add max:number
to the versioning object to limit the number of stored versions.
max
The new limit
Number
This is only for file versions. To read a temporary version, access it from db.versions.temp
If you know the ISO date for the version you would like to read (programmatically), you can use readFromDate
tag
Record tag
String
date
Date of version
String (ISO date)
You can stop versioning anytime; the parameters are the same as the initialization.