I had a server still using MariaDB JDBC 2.7.3 from an old install. I saw that version 3.3.3 was sitting in jdbc-bundled and decided to upgrade to that. I grabbed the file out of that directory and upgraded as per these instructions. The DB connection bounced momentarily and came back up and everything seems to be working.
But ... both versions of the MariaDB JDBC files are in the same places as before under ./user-lib/
and I can't find any place in the log that spits out which JDBC version is in use. How can I confirm that the upgrade actually did anything?
This is what the files looked like both before and after the upgrade:
justin@ignition:/usr/local/bin/ignition$ find . -iname "*maria*" -exec sha256sum {} \;
7c823b2f8fdda522a7f76e69cb287482b46247c135c4c44b27b98fb2ae092747 ./temp/jdbc/mariadb-java-client-2.7.36958885001544908716.jar
89d71a6ffd800c032b23e588108688d391631f0aba962ba2381cc82cb111b796 ./user-lib/jdbc-bundled/mariadb-java-client-3.3.3.jar
7c823b2f8fdda522a7f76e69cb287482b46247c135c4c44b27b98fb2ae092747 ./user-lib/jdbc/mariadb-java-client-2.7.3.jar
I expected the upgrade process to move the new one into ./user-lib/jdbc/
directly.
I think you need to remove the old one to be sure about anything.
edit: I think you want to add the 3.3.3 JAR file in ./user-lib/jdbc/
and delete the 2.7.3 file. The jdbc-bundled
folder is used by the installer during upgrades to stash possibly-newer version of JDBC drivers but not replace your existing ones.
Okay... I tried the JDBC upgrade a second time, and this time it definitely did something:
justin@ignition:/usr/local/bin/ignition$ find . -iname "*maria*" -exec sha256sum {} \;
89d71a6ffd800c032b23e588108688d391631f0aba962ba2381cc82cb111b796 ./temp/jdbc/mariadb-java-client-3.3.31472352354373245713.jar
7c823b2f8fdda522a7f76e69cb287482b46247c135c4c44b27b98fb2ae092747 ./temp/jdbc/mariadb-java-client-2.7.36958885001544908716.jar
89d71a6ffd800c032b23e588108688d391631f0aba962ba2381cc82cb111b796 ./user-lib/jdbc-bundled/mariadb-java-client-3.3.3.jar
89d71a6ffd800c032b23e588108688d391631f0aba962ba2381cc82cb111b796 ./user-lib/jdbc/mariadb-java-client-3.3.3.jar
I feel like the first time somehow failed and I didn't get any obvious feedback.
I upgraded to the newest version of MariaDB before Christmas, and all of my connections went bad. Turns out I needed to upgrade the JDBC driver too.
I upgraded the same way that you described, except I pulled the latest driver from MySQL :: Download Connector/J
After updgrading the driver, the connections started working again, and my /jdbc
directory looks like this
It obviously switched to the newest one since my connections went back to good, but they both still exist in the folder, but it does not tell you specifically which one is in use.
Okay, I think for JDBC drivers it's not just loading everything in there, but rather, only the JAR file(s) specified by the JDBC record in the internal DB... but I'm not certain without digging into it further.