MySQL extension with MariaDB connector docs#11608
MySQL extension with MariaDB connector docs#11608clintropolis merged 5 commits intoapache:masterfrom
Conversation
techdocsmith
left a comment
There was a problem hiding this comment.
some typos & style changes.
| This module can be used side to side with other lookup module like the global cached lookup module. | ||
|
|
||
| To use this extension please make sure to [include](../../development/extensions.md#loading-extensions) `druid-lookups-cached-single` as an extension. | ||
| To use this extension please make sure to [include](../extensions.md#loading-extensions) `druid-lookups-cached-single` as an extension. |
There was a problem hiding this comment.
| To use this extension please make sure to [include](../extensions.md#loading-extensions) `druid-lookups-cached-single` as an extension. | |
| To use this extension [include](../extensions.md#loading-extensions) `druid-lookups-cached-single` as an extension. |
There was a problem hiding this comment.
should this be something like
... include
druid-lookups-cached-singlein the extension load list.
so it isn't
this extension ... as an extension.
?
| > For Postgres, the connector JAR is already included. | ||
| > For MySQL, you can get it from https://dev.mysql.com/downloads/connector/j/. | ||
| > Copy or symlink the downloaded file inside the folder `extensions/druid-lookups-cached-single` under the distribution root directory. | ||
| > See the MySQL extension documentation for instructions on how to obtain for [MySQL](./mysql.md#installing-the-mysql-connector-library) or [MariaDB](./mysql.md#alternative-installing-the-mariadb-connector-library) connector libraries. |
There was a problem hiding this comment.
| > See the MySQL extension documentation for instructions on how to obtain for [MySQL](./mysql.md#installing-the-mysql-connector-library) or [MariaDB](./mysql.md#alternative-installing-the-mariadb-connector-library) connector libraries. | |
| > See the MySQL extension documentation for instructions to obtain [MySQL](./mysql.md#installing-the-mysql-connector-library) or [MariaDB](./mysql.md#alternative-installing-the-mariadb-connector-library) connector libraries. |
| > Lookups are an [experimental](../experimental.md) feature. | ||
|
|
||
| To use this Apache Druid extension, make sure to [include](../../development/extensions.md#loading-extensions) `druid-lookups-cached-global` as an extension. | ||
| To use this Apache Druid extension, make sure to [include](../extensions.md#loading-extensions) `druid-lookups-cached-global` as an extension. |
There was a problem hiding this comment.
| To use this Apache Druid extension, make sure to [include](../extensions.md#loading-extensions) `druid-lookups-cached-global` as an extension. | |
| To use this Apache Druid extension, [include](../extensions.md#loading-extensions) `druid-lookups-cached-global` as an extension. |
| > If using JDBC, you will need to add your database's client JAR files to the extension's directory. | ||
| > For Postgres, the connector JAR is already included. | ||
| > For MySQL, you can get it from https://dev.mysql.com/downloads/connector/j/. | ||
| > See the MySQL extension documentation for instructions on how to obtain for [MySQL](./mysql.md#installing-the-mysql-connector-library) or [MariaDB](./mysql.md#alternative-installing-the-mariadb-connector-library) connector libraries. |
There was a problem hiding this comment.
| > See the MySQL extension documentation for instructions on how to obtain for [MySQL](./mysql.md#installing-the-mysql-connector-library) or [MariaDB](./mysql.md#alternative-installing-the-mariadb-connector-library) connector libraries. | |
| > See the MySQL extension documentation for instructions to obtain [MySQL](./mysql.md#installing-the-mysql-connector-library) or [MariaDB](./mysql.md#alternative-installing-the-mariadb-connector-library) connector libraries. |
| To use this Apache Druid extension, make sure to [include](../../development/extensions.md#loading-extensions) `mysql-metadata-storage` as an extension. | ||
|
|
||
| > The MySQL extension requires the MySQL Connector/J library which is not included in the Druid distribution. | ||
| > The MySQL extension requires the MySQL Connector/J library or MariaDB Connector/J library, neither of which is not included in the Druid distribution. |
There was a problem hiding this comment.
| > The MySQL extension requires the MySQL Connector/J library or MariaDB Connector/J library, neither of which is not included in the Druid distribution. | |
| > The MySQL extension requires the MySQL Connector/J library or MariaDB Connector/J library, neither of which are included in the Druid distribution. |
Double negative. Looks like neither are included.
| THis extension also supports using the MariaDB connector jar, though it is also not included in the Druid distribution and must be installed separately like the MySQL connector. | ||
|
|
||
| - Download from the MariaDB site: https://mariadb.com/downloads/connector | ||
| - Maven Central: https://repo1.maven.org/maven2/org/mariadb/jdbc/mariadb-java-client/2.7.3/mariadb-java-client-2.7.3.jar |
There was a problem hiding this comment.
| - Maven Central: https://repo1.maven.org/maven2/org/mariadb/jdbc/mariadb-java-client/2.7.3/mariadb-java-client-2.7.3.jar | |
| - Download from Maven Central: https://repo1.maven.org/maven2/org/mariadb/jdbc/mariadb-java-client/2.7.3/mariadb-java-client-2.7.3.jar |
| - Download from the MariaDB site: https://mariadb.com/downloads/connector | ||
| - Maven Central: https://repo1.maven.org/maven2/org/mariadb/jdbc/mariadb-java-client/2.7.3/mariadb-java-client-2.7.3.jar | ||
|
|
||
| This should fetch a JAR file named similar to 'maria-java-client-x.x.x.jar'. |
There was a problem hiding this comment.
| This should fetch a JAR file named similar to 'maria-java-client-x.x.x.jar'. | |
| This fetches the MariaDB connector JAR file with a name like 'maria-java-client-x.x.x.jar'. |
|
|
||
| Copy or symlink this file to `extensions/mysql-metadata-storage` under the distribution root directory. | ||
|
|
||
| In Druid properties, `druid.metadata.mysql.driver.driverClassName=org.mariadb.jdbc.Driver` must be set, which will instruct the `mysql-metadata-storage` extension to use the MariaDB connector library instead of MySQL. Depending on the MariaDB client library version, it will support both `jdbc:mysql:` and `jdbc:mariadb:` connection URIs, though the parameters to configure the connection vary between implementations, so be sure to [check the documentation](https://mariadb.com/kb/en/about-mariadb-connector-j/#connection-strings) for details. |
There was a problem hiding this comment.
| In Druid properties, `druid.metadata.mysql.driver.driverClassName=org.mariadb.jdbc.Driver` must be set, which will instruct the `mysql-metadata-storage` extension to use the MariaDB connector library instead of MySQL. Depending on the MariaDB client library version, it will support both `jdbc:mysql:` and `jdbc:mariadb:` connection URIs, though the parameters to configure the connection vary between implementations, so be sure to [check the documentation](https://mariadb.com/kb/en/about-mariadb-connector-j/#connection-strings) for details. | |
| To configure the `mysql-metadata-storage` extension to use the MariaDB connector library instead of MySQL, set the following in the Druid properties: `druid.metadata.mysql.driver.driverClassName=org.mariadb.jdbc.Driver` | |
| Depending on the MariaDB client library version, the connector supports both `jdbc:mysql:` and `jdbc:mariadb:` connection URIs. However, the parameters to configure the connection vary between implementations, so be sure to [check the documentation](https://mariadb.com/kb/en/about-mariadb-connector-j/#connection-strings) for details. |
| [http://dev.mysql.com/downloads/mysql/](http://dev.mysql.com/downloads/mysql/) | ||
| [http://dev.mysql.com/downloads/mysql/](http://dev.mysql.com/downloads/mysql/). | ||
|
|
||
| This extension should also function correctly using MariaDB server, https://mariadb.org/download/, substituting for MariaDB in the following instructions where appropriate. |
There was a problem hiding this comment.
| This extension should also function correctly using MariaDB server, https://mariadb.org/download/, substituting for MariaDB in the following instructions where appropriate. | |
| This extension should also supports MariaDB server, https://mariadb.org/download/, substituting for MariaDB in the following instructions where appropriate. |
| druid.metadata.storage.connector.password=diurd | ||
| ``` | ||
|
|
||
| If using MariaDB, `druid.metadata.mysql.driver.driverClassName=org.mariadb.jdbc.Driver` must also be set. |
There was a problem hiding this comment.
| If using MariaDB, `druid.metadata.mysql.driver.driverClassName=org.mariadb.jdbc.Driver` must also be set. | |
| If using MariaDB, set `druid.metadata.mysql.driver.driverClassName=org.mariadb.jdbc.Driver`. |
|
hmm, we need to figure out how to make the code coverage bot ignore log statements I think... |
|
skipping CI since changes are basically doc only, and those jobs are passing |
Follow-up to #11402, adding docs for using MySQL extension with MariaDB connector library. Also, a log statement so Druid reports which driver class it is attempting to use.