Version 8.0.28 is the latest General Availability release of the 8.0 series of MySQL Connector/J. It is suitable for use with MySQL Server versions 8.0 and 5.7. It supports the Java Database Connectivity (JDBC) 4.2 API, and implements the X DevAPI.
-
The TLSv1 and TLSv1.1 connection protocols were deprecated in Connector/J 8.0.26 and are now removed in this release. The removed values are considered invalid for use with connection options and session settings. Connections can be made using the more-secure TLSv1.2 and TLSv1.3 protocols. Using TLSv1.3 requires that the server be compiled with OpenSSL 1.1.1 or higher and Connector/J be run with a JVM that supports TLSv1.3 (for example, Oracle Java 8u261 and above).
Also, the following connection properties have been renamed:
enabledTLSProtocolsrenamed to tlsVersions; the original name remains as an alias.enabledSSLCipherSuitesrenamed to tlsCiphersuites; the original name remains as an alias.
(WL #14805)
X DevAPI: A document
_idcheck has been added to theCollection.addOrReplaceOne(id, doc)andCollection.replaceOne(id, doc)methods: If theidsupplied as an argument for the functions does not match the_idindoc(the supplied JSON document), the operation fails. (Bug #32770013)Connector/J now supports multifactor authentication for connections to MySQL Servers. Three new connection properties, password1, password2, and password3, have been added for that purpose. See Connecting Using Multifactor Authentication for details. (WL #14650)
The
READMEfile in the Connector/J distribution contained broken links in the Additional Resources section. (Bug #33507321)Storing a
java.time.LocalDateobject onto the server as aDATEvalue using a batchedPreparedStatementfailed with the complaint thatjava.time.LocalDatecould not be cast tojava.sql.Date. With this fix, the object is encoded correctly into aDATEvalue. (Bug #33468860, Bug #105211)ResultSetnavigation methods likeabsolute(),relative(),first(),last(), and so on returned aNullPointerExceptionwhen they were applied to a non-navigableResultSet. This was because the methods did not check if theResultSetreally had any rows before trying to navigate it. This patch makes all navigation methods perform the check and throw a properSQLExceptionwhen theResultSethas no rows. (Bug #33461744)Running a
PreparedStatementin the form ofINSERT INTO ... VALUE ... ON DUPLICATE KEY UPDATE ... VALUES(...)resulted in aStringIndexOutOfBoundsException. It was because Connector/J did not recognizeVALUEas an alias forVALUESin anINSERTstatement, and mistook theVALUES()function as aVALUESclause for the statement. With this fix, statements like this are parsed properly. (Bug #33425867, Bug #84365)When the connection session's character set was SJIS,
BLOBvalues could not be handled properly by client-side prepared statements. (Bug #33350185)Some Java frameworks prevent changes of the
autocommitvalue on the MySQL Server. When an application tried to changeautocommit, the value was changed for the connectionSessionon the client side, but it failed to change on the server, so the settings became out of sync. With this fix, Connector/J resetsautocommitto its original value for theSessionunder the situation. Thanks to Tingyu Wei for contributing to the fix. (Bug #33054827, Bug #104067)getWarnings()always sent aSHOW WARNINGSquery to the server. With this fix, the query is sent only if there really are warnings to be shown, in order to save resources. (Bug #32089018, Bug #101389)After calling
Statement.setQueryTimeout(), when a query timeout was reached, a connection to the server was established to terminate the query, but the connection remained open afterward. With this fix, the new connection is closed after the query termination. (Bug #31189960, Bug #99260)A new session created for executing
Statement.cancel()remained open after theStatementhad been cancelled. With this fix, the session is closed after theStatementcancellation. (Bug #30355150, Bug #96900)Using the
setString()method on anSQLXMLobject resulted in aNullPointerException. (Bug #25656020, Bug #85223)