You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 5 Next »
The SimpleOne system allows exporting and importing configuration packs to keep unrelated instances synchronized.
Concept
In brief, the VCS configuration pack conception can be defined as an ability to transfer data from one instance to another, in an automatic or semi-automatic way. It is intended for application version control. Configuration packs help to automate transfer data and configurations from one instance to another, lessen the manual effort. The key point is configurations transfer, for not to reiterate it more and more on every instance, you can just import a configuration pack. So, this technology really is to make it easy and automate a migration update from one instance to another.
Application configurations are stored in configuration packs which are represented as a .SOP file containing a set of the application version records. In an OOB supply, the SimpleOne platform contains only the Simple application, but administrators (users with the admin role) can create their own Applications if needed.
There can be more than one local pack in the system, but the changes made by a single source can be written only in one localpack at every moment. You can choose the preferable localpack using the Preferences menu at the right. Please refer to the Interface#AdminPreferences article for the details.
Initially, the configuration pack should be assembled on the source instance (the instance containing source data) within the local pack related to the specific application. After that, the local pack can be exported to the configuration pack as a .SOP file.
Please note: all system configuration activities should be performed within a detached local pack (do not use default local pack for these needs).
Using configuration packs allows deploying this configuration on other instances, or, if needed, rollback versions of the specified record or some local pack as a whole to the previous state.
Technically, the configuration pack is the set of the saved records of the VCS Record (sys_vcs_record) table. Every record of this table contains JSON formatted changes and other attributes described below.
{"value": "Report Item", "policy": "Open", "sys_id": 159653803414986194, "column_id": 156941403909472422, "record_id": 159653803414985080, "language_id": 156628684306541141, "application_id": 155931135900000002, "sys_created_at": "2020-08-04 10:47:14", "sys_created_by": 155931135900000001, "sys_updated_at": "2020-08-04 10:47:14", "sys_updated_by": 155931135900000001}
The configuration pack transfer between instances can be also called "import". On the picture below, you can find the cross-instance configuration versions import flow:
Record versions
After any transaction (create/update/delete) for the versioned table object, the record is created in the VCS Record (sys_vcs_record) table corresponding to the object state after the transaction. The record version contains the information described below.
VCS Record form fields
Field | Description |
---|---|
Record | An ID of the source record processed by the transaction. |
Table name | The table name for the target record. Please note that only system names for tables are used in this field, not titles. Right: sys_vcs_record. Wrong: VCS record. |
Record document | This ID stores table name and target record ID for which the current record is created. For example: |
Is Current | This attribute is responsible for current version relevance. When its value is equal to TRUE, then the version corresponds to the target record state relevant for now. |
JSON Copy | The record version data in JSON format as an associative array. This array stores the target record object relevant state after the transaction. |
Action | Transaction type. Available options:
|
Local pack | Reference to the local pack containing this record version. |
Retrieved pack | Reference to the configuration pack containing this record version. |
Restored by | The ID of the record version from which the current version has been restored. |
Platform version | The solution platform version used for version creating. |
Application | A related application containing the target record. |
Is Strong Overwrite | If this attribute value is equal to TRUE, then this version will take precedence over the existing version when the import process will go on. |
Record Policy | The current record protection policy after the transaction is over. |
Local packs
Technically, a local pack is a record in the VCS Local Pack (sys_vcs_local_pack) table related to versions of the related records in a VCS Record (sys_vcs_record) table. Every single version is an atomic state of versioned tables (those ones which have the is_VCS_enabled attribute turned ON). All record versions in the local pack are displayed on a related list on a local pack form.
To create a local pack, please complete the steps below:
- Navigate to Configuration Pack → Local Packs.
- Click New and fill in the fields.
- Click Save or Save and Exit to apply changes.
VCS Local Pack form fields
Field | Description |
---|---|
Origin ID | This ID is assigned to the local pack after creating it on a source instance. |
ID | This ID is assigned to the local pack after importing. |
Is Default | This attribute defines that this local pack will be set as default for any user changing the application to the one specified in the Application field. |
Application | Specify an application of which record changes are stored in this local pack. |
Name | Local pack name. |
Description | Local pack description. |
State | Local pack state. Available options:
|
Completed at | The date and time when the local pack state changed to Completed. |
Completed by | Reference to the user who has set the state to Completed. |
Version restoring
A non-actual version (the is_current attribute value is equal to FALSE) can be restored if needed. To perform this, please complete the steps below:
- Navigate to Configuration Pack → Records.
- Find the record to be recovered. You can use list search for search criteria narrowing, or a Condition Builder.
- Click on a desirable record to navigate into it.
- Click Restore Version.
After that, a new VCS record is created in the current local pack; the Restored by field value of this record is equal to the ID of the version used for restoring.
You can add a versions list to the versioned table form as a related list. After that, all previous versions of the current record are displayed on the record form.
Default local pack
Default local pack is a local pack named "Default 1" created automatically after creating a new application. It is not recommended to use this local pack to store versions for the purpose of further import to other instances; create separate packs for these tasks.
If a version has been created in a default local pack erroneously, then you can move it to the required local pack. For this, please complete the steps below:
- Navigate to Configuration Pack → Records.
- Find the record to be recovered. You can use list search for search criteria narrowing, or a Condition Builder.
- Click on a desirable record to navigate into it.
- Click the magnifier icon on the left of the Local Pack field and choose the required local pack.
- Click Save or Save and Exit to apply changes.
Local Pack Exporting
- No labels