The Oracle MySQL and the MariaDB JDBC connectors are already included in the CMS package.
Since version 5.29.0, MariaDB Connector/J is the default connector for MySQL. However you can change the following setting to let the CMS use the Oracle MySQL JDBC connector instead:
$SETTINGS["driverClass"] = "com.mysql.jdbc.Driver";
Read the documentation for ContentRepositories to do the same for ContentRepositories.