The test-project module contains Maven plugin to run changelog files.
- In the root of test-project you can find
pom.xml
file where Maven plugin is located. This plugin requires an extension dependency. You need to set required dependency.- Get desired version (better latest) of extension from https://mvnrepository.com/artifact/org.liquibase.ext/liquibase-couchbase and set it in
pom.xml
of test-project to theliquibase-maven-plugin
- At first, you need to choose branch from which you want to create dependency and put to local repository for test purpose. When you chose the branch create jar (dependency) of it
To do this, executemvn clean install
command in the root of the liquibase-couchbase module through CLI or using IDE. Make sure that inpom.xml
of test-project theliquibase-maven-plugin
has the correct version of our created dependency.
- Get desired version (better latest) of extension from https://mvnrepository.com/artifact/org.liquibase.ext/liquibase-couchbase and set it in
- Change the properties (URL, username, password for the Couchbase database) in the
src\main\resources\liquibase.properties
. - Write changelog files into the
src\main\resources\liquibase\changelog
directory. - Run the update command (apply all new changes). We can do this:
- In the root of the test-project invoke the
mvn liquibase:update
command; - Using and IDE (Intellij IDEA for example) navigate to maven -> test-project -> plugins -> liquibase -> liquibase:update and invoke it.
- In the root of the test-project invoke the
- In test-project in the
src\main\resources
folder there is aliquibase-couchbase.properties
file. In this file, there are properties specific for our Couchbase extension, such as transaction timeout, enable or disable reactive transactions, bucket for history data etc. (Full list you can see in main README -> Properties section couchbase-liquibase).
To make these properties work, you also need to applymvn clean install
on test-project module. Because now these properties can only be read if we have jar file.
And every time when we change these properties we need to recreate jar so that the new values are read.