I’m currently updating liquibase from 3.10.3 to 4.18.0. I got problems with custom change set where our code also does property substituting.
Substituting Properties in Changelogs | Liquibase Docs
In that page it says:
Note: If you do not want to replace an otherwise matching
${property-name}
expression, add:
to the beginning of the expression. An expression of${: property-name}
will always be converted to${property-name}
regardless of whetherproperty-name
is defined.
One side note: It says that add “:” but example contains space. Maybe this is documentation issue.
But should this work? I tried “${: property-name}” and “${:property-name}”. With and without space. But those are not changed to expected “${property-name}” value.
Here is an example of one change set and what liquibase writes into log (find&replace was used to hide private information):
<changeSet author="nn" id="u/AAU" runOnChange="true">
<customChange class="e.a.d.i.SC">
<param name="updateFileName" value="u/AAU.sql"/>
<param name="parameters" value="$${:language.${:country}};${:aa.p}"/>
</customChange>
</changeSet>
[8:11:28|FINE]: Computed checksum for customChange:[
class=“e.a.d.i.SC”
param={
parameters=“$${:language.${:country}};${:aa.p}”,
updateFileName=“u/AAU.sql”
}