We're updating the issue view to help you get more done. 

Cannot load changelog parameters via properties when using maven

Description

I am trying to load changelog parameters via a properties file as described in the documentation.
I am using maven to run liquibase (goals update / updateSQL), but I get always the same result:

  • maven shows a warning in the beginning: `'parameter.indexTablespace' in properties file is not being used by this task.`

  • the parameter is not initialized and `updateSQL` produces output having the parameters not interpolated

Command:
` mvn liquibase:updateSQL`

Configuration:

pom.xml

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 <properties> <liquibase.propertyFile>src/main/env/dev.properties</liquibase.propertyFile> <liquibase.changeLogFile>src/main/resources/db/changelog/master-changelog.xml</liquibase.changeLogFile> <liquibase.verbose>false</liquibase.verbose> </properties> ... <pluginManagement> <plugins> <plugin> <groupId>org.liquibase</groupId> <artifactId>liquibase-maven-plugin</artifactId> <version>3.6.2</version> </plugin> </plugins> </pluginManagement>

Properties:

1 parameter.indexTablespace=MYAPPINDEX

Changelog:

1 2 3 4 5 6 7 8 ... <changeSet author="bartacek" id="index-domain"> <createIndex indexName="UX_MYDOMAIN_EXTID" tableName="MYUSER" unique="true" tablespace="${indexTablespace}"> <column name="DOMAINID"/> <column name="EXTERNAL_ID"/> </createIndex> </changeSet> ...

Result:

1 CREATE UNIQUE INDEX UX_MYUSER_DOMAIN_EXTID ON MYUSER(DOMAINID, EXTERNAL_ID) TABLESPACE ${indexTablespace};

Expected result:

1 CREATE UNIQUE INDEX UX_MYUSER_DOMAIN_EXTID ON MYUSER(DOMAINID, EXTERNAL_ID) TABLESPACE MYAPPINDEX;

Environment

???

Status

Assignee

Unassigned

Reporter

Vaclav Bartacek

Labels

None

Components

Affects versions

3.6.2

Priority

Major