Q:

Liquibase maven plugin, issue with my database driver

I am trying use liquibase maven plugin to generate changelog xml file. I add plugin to my pom file like below.
            <plugin>
            <groupId>org.liquibase</groupId>
            <artifactId>liquibase-maven-plugin</artifactId>
            <configuration>
                <propertyFile>web/src/main/resources/liquibase.properties</propertyFile>
                <changeLogFile>web/src/main/resources/data/changelog/db.changelog-master.xml</changeLogFile>
            </configuration>
        </plugin>

I am using liquibase.properties: 
url=jdbc:mysql://127.0.0.1:3306/recproject_test? 
useUnicode=yes&characterEncoding=UTF-8
username=recproject
password=sample
classpath=/repository/mysql/mysql-connector-java/5.1.38/mysql-connector- 
java-5.1.38.jar
changeLogFile=web/src/main/resources/data/changelog/db.changelog-1.0.0.xml

But when I run liquibase:generateChangeLog as a maven goal I get: 
Error setting up or running Liquibase: liquibase.exception.DatabaseException: java.lang.RuntimeException: Cannot find database driver: com.mysql.cj.jdbc.Driver

I store /mysql-connector-java jar in External Libraries and classpath in liquibase.properites is a path to this file.

A:

I've downloaded mysql-connector-java-5.1.38.jar from here but it doesn't contain com.mysql.cj.jdbc.Driver.
So you should use database driver com.mysql.jdbc.Driver or download newer version of driver if you want to use com.mysql.cj.jdbc.Driver .

