[CONJ-1103] Connector/J Version 3 Does Not Respect "nullCatalogMeansCurrent" Property Created: 2023-08-22  Updated: 2023-08-22

Status: Open
Project: MariaDB Connector/J
Component/s: metadata
Affects Version/s: 3.1.4
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Jeff Butler Assignee: Diego Dupin
Resolution: Unresolved Votes: 0
Labels: None


 Description   

MyBatis Generator uses DatabaseMetaData to introspect databases. Starting with version 3 of the MariaDB driver, we are finding that the driver no longer honors the "nullCatalogMeansCurrent" property. So our introspection runs are returning data from the information_schema where they didn't before.

I can see in the following source that the property is mentions in the JavaDoc, but the code does not actually check the value of the property. Here's the relevant method:

https://github.com/mariadb-corporation/mariadb-connector-j/blob/7ddcd9eea4cd4379cb84638b0a68776165f103dc/src/main/java/org/mariadb/jdbc/DatabaseMetaData.java#L566-L607

Here is the equivalent method in the 2.x line that is respecting the property value:

https://github.com/mariadb-corporation/mariadb-connector-j/blob/28f1269b0df58cd87fbb4fa3e44021e440e34c2f/src/main/java/org/mariadb/jdbc/MariaDbDatabaseMetaData.java#L587-L621


Generated at Thu Feb 08 03:20:38 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.