Redshift extension

how do configure liquibase.properties using redshift extension?
i’m referencing the jar:

classpath: src/main/resources/liquibase-redshift-3.10.1.jar

tried both
driver: com.amazon.redshift.jdbc42.Driver
or
driver: com.amazon.redshift.jdbc.Driver

and i keep getting an error
“Cannot find database driver: com.amazon.redshift.jdbc.Driver”

using JDBC driver works fine, but the changelog file does not contain sort keys, dist keys
this is how how configured the connection that worked but didn’t import sort keys and dist keys:

driver: com.amazon.redshift.jdbc42.Driver
classpath: src/main/resources/RedshiftJDBC42-1.2.16.1027.jar

would love some help here

Hi @gili, welcome to the forum!

I have seen this issue before, what version of Liquibase are you using?

A known workaround is to put the url, user and password in the commandline and not take values from the liquibase properties file

liquibase --url="[JDBCURL]" --username=scott --password=tiger

Where JDBCURL could be something like: jdbc:redshift://examplecluster.abc123xyz789.us-west-2.redshift.amazonaws.com:5439/dev

Which my collegue @MikeOlivas found on this page.

If you try that, do you get the same error message?

-Ronak

yes, i do get the same error “Cannot find database driver: …”
ran the command this way:

liquibase --changeLogFile=changelog.redshift.sql --schemas=atomic,agg --includeSchema=true --includeTablespace=true --url=“jdbc:redshift:xxxxxx.xxxxxx.us-east-1.redshift.amazonaws.com:5439/xxxx” --username=xxxx --password=xxxxx generateChangeLog

does the redshift extention solve the sort key/dist key issue? can i except generateChangeLog command generate the sort and dist keys when using classpath: src/main/resources/liquibase-redshift-3.10.1.jar?

Hey @gili, (cc @MikeOlivas)

Just had this issue brought up in standup, looks like this discussion issue is not up to date. I hear you have been able to connect? And now you are getting an error I believe in snapshotting?

If there is an error, could we move this to reporting the bug on the redshift extension if the above is true:

Would you also mind sharing the connection string that worked for you so we can add that to documentation and it could help out others that had the same issue you did?

Thanks!

Ronak