...
The change-log will then be updated running the following yaml files in order, based on the changelog-master.yaml file within the cps-ri->src->main->resources->changelog→dbri→ src→ main→ resources→ changelog→db.changes directory.
Note |
---|
Anytime a new change-log YAML is added, it will need to be included in this file for the changes to be applied within CPS |
...
The data for each table is defined using the CSV files located within cps-ri->resources->changelog->db.changes->data→dmiri→ resources→ changelog→db.changes→ data→dmi.
Code Block | ||||
---|---|---|---|---|
| ||||
renamed_column|new_column1|new_column2 test_table_column_name|columnValue|3 |
...
First copy the content from the CSV file above and create a YANG file locally with it with the format 'dmi-registry@*revision*registry@<revision>'.
Run the following command to insert a new yang resource into the yang_resource table with the checksum generated.
...
Create a csv to define the data in the format of 'schema_set_yang_resources@*revsision*resources@<revision>'
Code Block | ||||||
---|---|---|---|---|---|---|
| ||||||
schema_set_id|yang_resource_id (select id from schema_set where name='ncmp-dmi-registry-model')|(select id from yang_resource where name='dmi-registry@2021-12-13.yang') |
...
Code Block | ||||
---|---|---|---|---|
| ||||
mvn compile org.liquibase:liquibase-maven-plugin:4.3.1:rollback -Dliquibase.rollbackCount=*number-of-change-sets-to-rollback*<number of change sets to rollback> -Dliquibase.url=jdbc:postgresql://localhost:5432/cpsdb -Dliquibase.username=cps -Dliquibase.password=cps -Dliquibase.changeLogFile=src/main/resources/changelog/changelog-master.yaml |
...
Code Block | ||||
---|---|---|---|---|
| ||||
mvn compile org.liquibase:liquibase-maven-plugin:4.3.1:rollback -Dliquibase.rollbackTag=*liquibase-tag-to-rollback-to*<liquibase tag to rollback to> -Dliquibase.url=jdbc:postgresql://localhost:5432/cpsdb -Dliquibase.username=cps -Dliquibase.password=cps -Dliquibase.changeLogFile=src/main/resources/changelog/changelog-master.yaml |
...
Code Block | ||||
---|---|---|---|---|
| ||||
mvn compile org.liquibase:liquibase-maven-plugin:4.3.1:rollback -Dliquibase.rollbackDate=*date-to-rollback-to*<date to rollback to> -Dliquibase.url=jdbc:postgresql://localhost:5432/cpsdb -Dliquibase.username=cps -Dliquibase.password=cps -Dliquibase.changeLogFile=src/main/resources/changelog/changelog-master.yaml |
...