I’m using Maven to run Liquibase and I get this error:
‘classpath’ in properties file is not being used by this task
I’m using a properties file as follows for an update goal:
changeLogFile=/somedir/changelog.xml
username=scott
password=password
url=jdbc:oracle:thin:@//localhost:1521/mydb
driver=oracle.jdbc.OracleDriver
classpath=…/…/ojdbc14-10.2.0.1.0.jar
Here’s the POM file plugin info:
org.liquibase
liquibase-plugin
1.6.1.0
process-resources
true
resources/liquibase.properties
true
update
Here’s the console output:
INFO] Parsing Liquibase Properties File
[INFO] File: /Users/swillcox/projects/alm/alm-tool-oracle/target/liquibase.properties
[INFO] ‘classpath’ in properties file is not being used by this task.
[INFO] ------------------------------------------------------------------------
[INFO] Settings----------------------------
[INFO] driver: oracle.jdbc.OracleDriver
[INFO] url: jdbc:oracle:thin:@//localhost:1521/mydb
[INFO] username: scott
[INFO] password: password
[INFO] use empty password: false
[INFO] properties file: /Users/swillcox/projects/alm/alm-tool-oracle/target/liquibase.properties
[INFO] properties file will override? true
[INFO] prompt on non-local database? true
[INFO] clear checksums? false
[INFO] changeLogFile: /somedir/changelog.xml
[INFO] drop first? false
[INFO] context(s): null
[INFO] number of changes to apply: 0
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error setting up or running Liquibase: java.lang.RuntimeException: Cannot find database driver: oracle.jdbc.OracleDriver
As you can see it is ignoring the classpath property and as a result can not find the driver.
Any idea why it is ignoring the classpath property?