After loading a .SOP file into a retrieved pack record, the system checks if VCS records may cause errors. Generally, collisions may appear during the configuration pack import process.

Consider a common use case:

  1. We have exported a Business Rule record.
  2. We import it to the target instance which has the same Business Rule record updated later, that is, this record is newer.
  3. The collision is thrown: the target instance has a newer version of this record.

You can find the erroneous record in the VCS Preview Log related list of in the VCS Retrieved Pack records. These records store the error cause in the Message field and have the following states:

StateDescription
CollisionRecord in this state requires user's attention and will not be implemented until the collision is solved.
SkippedRecord in this state will be ignored while implementing the pack.
WarningThis state highlights valid records having minor mismatches. Depending on the error, records will be implemented or ignored.

You can solve some collisions by completing the following steps:

  1. In the configuration pack you need, scroll down to the Related Lists area and open the VCS Preview Log tab.
  2. Filter out records in the Good state using the Condition Builder.
  3. Open a record from the selection.
  4. Read the text in the Message field to find the error cause.
  5. Open the corresponding record in the Retrieved Records related list.
  6. Make necessary changes to the retrieved record in the JSON Copy field.

    In some cases, especially when the version records need complex fixes, it is preferable to configure the erroneous records on the source instance and try to implement fixed configuration pack once again.

  7. Click Save or Save and Exit to apply changes.
  8. Return to the configuration pack record and click Prepare changes.
  9. Make sure that the VCS Preview Log record state has changed to Good.
  10. Repeat these steps until all necessary records in the VCS Preview Log are in the Good state.
  11. When all necessary records in the VCS Preview Log are in the Good state, click Import pack.


If a record can potentially cause multiple collisions, the system will display only the first collision. Process the collision and click Prepare changes to see the next collision caused by this record.


Collisions cases


Collision case 1

When installing a configuration pack in the system, some record X is added. At the same time, it references another record Y in this system and in this configuration pack. The Y record that the record X is referenced to does not exist. After loading the pack, a VCS record has the following Message:

Reference {sys_id} in {column_name} does not exists in referenced table {reference_table_name}

If the reference field has the No Action value in the On Delete field, the record will be implemented without any collisions. See the Reference Fields article to learn more about referencing.

Collision solving:

The solution is to add the Y record to this configuration pack on the source instance.


Collision case 2

The record X is deleted from the system. At the same time, there is a reference to this record in the configuration pack. After loading the pack, a VCS record has the following Message:

{column_name} column in {reference_table_name} table referenced on this record;

Collision solving:

The solution is to change the X record state to Skipped.

Collision case 3

Mismatch in the set of fields while importing records between alike tables.

Details:

  1. The User table on the source instance has the N set of fields (see the Source lane in the scheme below).
  2. The User table on the target instance has the N-1 set of fields (see the Target lane lacking the manager column).
  3. After loading the pack containing records from the table with the N field set, a VCS record has the following Message:

Column "manager" related to "user" does not exist.

Collision solving:

  • Continue import with the Warning state. In this case, the column will not be created, and the imported records will have the N-1 set of fields.

OR

  • Import the lacking column into the target instance so that the table with N-1 fields becomes table with N fields. Then reload the initial local pack.

Collision case 4

The records on the target instance are newer than in the configuration pack to install. It can be determined by the date and time of record creation. Collision-causing records will be marked with the Skipped state. The Message is the following:

The system has a newer record

Collision solving:

  • Change the state to Good. In this case, the target instance records will be updated to those from the configuration pack.

OR

  • Keep the Skipped state to keep the target instance records without changes.

Collision case 5

In the configuration pack, a table is to be deleted but contains records (is not empty). Collision-causing records will be marked with the Skipped state. The Message is the following:

Table is not empty

Collision solving:

  • Change the state to Good. In this case, the table and all records will be deleted.

OR

  • Keep the Skipped state. The table will stay as it is.

Collision case 6

A configuration pack contains objects related to the application X. The target instance does not have this application installed. The Message is the following:

Related application "{application_id}" does not exist. Please repack this pack on the source instance

Collision solving:

The solution is to repack the configuration pack on the source instance in order to add records related to the missing application.

Collision case 7

The collision cause is a unique key violation.

Details:

  1. The importing configuration pack contains a record X1 from a table with UNIQUE CONSTRAINT.
  2. The target instance contains the same record with different ID, this is record X2. In other words, these two records have identical field values except the ID.
  3. After loading a pack to the target instance, a collision VCS record appeared containing the Message like this:

This record has a duplication of a unique key. DETAIL: Key (column_id, record_id, language_id)=(156941403909472422, 159170696512371798, 156628684306200767)

Collision solving:

  • Delete the X2 record on the target instance and click Prepare changes.

OR

  • Skip import of record X1.

Collision case 8

The column to be inserted exists on some level of inheritance.

Details:

  1. The target instance has table X and table Y, which extends from table X. That is, table Y is a child to table X, and therefore table Y inherits columns of table X. These columns belong to table X. See the Table Extension article to learn more.
  2. The configuration pack has a VCS record which inserts column A to table Y.
  3. At the same time, parent table X already has the same column A. That is, it the same column exists on a higher level of inheritance.
  4. After loading the pack, the VCS record contains the following Message:

A record for column A already created in the table X.

Collision solving:

The solution is to change the X record state to Skipped.

  • No labels