Documentation Home
MySQL Connector/J 8.0 Release Notes
Related Documentation

MySQL Connector/J 8.0 Release Notes  /  Changes in MySQL Connector/J 8.0.7 (2017-07-10, Development Milestone)

Changes in MySQL Connector/J 8.0.7 (2017-07-10, Development Milestone)

MySQL Connectors and other MySQL client tools and applications now synchronize the first digit of their version number with the (highest) MySQL server version they support. This change makes it easy and intuitive to decide which client version to use for which server version.

Connector/J 8.0.7 is the first release to use the new numbering. It is the successor to Connector/J 6.0.6.

Functionality Added or Changed

  • X DevAPI: There are changes to some methods related to the Result interface:

    • getLastDocumentId() and getLastDocumentIds() have been replaced with getDocumentId() and getDocumentIds(), which are put under a new AddResult interface that extends Result.

    • A new getAutoIncrementValue() method is added to the new InsertResult interface that extends Result.

    See MySQL Connector/J X DevAPI Reference for more details. (Bug #25207784)

  • X DevAPI: It is no longer permitted to pass an empty search condition, such as the NULL value or an empty string, to the Collection.Modify() and Collection.Remove() methods. (WL #10765)

  • X DevAPI: Connections using the X Protocol are now secure by default. Also, the xdevapi.ssl-enable connection option has been replaced by the xdevapi.ssl-mode option, which has DISABLED, REQUIRED (default), VERIFY_CA, and VERIFY_IDENTITY as its permitted values; see the description for the new option in Configuration Properties for details. (WL #10528)

  • X DevAPI: Consolidated the BaseSession, NodeSession, and XSession interfaces into a single com.mysql.cj.api.xdevapi.Session interface. The following related changes were also made:

    • Renamed XSessionFactory to SessionFactory.

    • Consolidated the AbstractSession, NodeSessionImpl, and XSessionImpl classes into the com.mysql.cj.xdevapi.SessionImpl class.

    • Removed the Session.bindToDefaultShard() method and the VirtualNodeSession interface.

    • The mysqlx.getNodeSession() method has been renamed to mysqlx.getSession() and it now returns a Session object.

    • The DatabaseObject.getSession() method now returns a Session object (instead of the old Session interface).

    See MySQL Connector/J X DevAPI Reference for more details. (WL #10530)

  • To avoid using JDBC statements inside core Connector/J classes, the following changes have been implemented:

    • Created a new com.mysql.cj.api.Query interface, which is implemented by StatementImpl.

    • Replaced the com.mysql.cj.api.jdbc.interceptors.StatementInterceptor interface with the com.mysql.cj.api.interceptors.QueryInterceptor interface.

    • Added a new method, PacketPayload preProcess(PacketPayload queryPacket), to QueryInterceptor.

    • Renamed the connection property statementInterceptors to queryInterceptors. See Configuration Properties for details.

    (WL #10305)

  • Added Japanese collation for the utf8mb4 character set. (WL #10553)

Bugs Fixed

  • X DevAPI: createView() failed with a NullPointerException when there were null inputs to it. This fix adds checks for nulls, and makes Connector/J throw the proper errors for them. (Bug #25575156)

  • X DevAPI: createaTable() failed with a NullPointerException when there were null inputs to it. This fix adds checks for nulls, and makes Connector/J throw the proper errors for them. (Bug #25575103)

  • X DevAPI: The connection properties enabledSSLCipherSuites, clientCertificateKeyStoreUrl, clientCertificateKeyStoreType, and clientCertificateKeyStorePassword were ignored for connections using the X Protocol. (Bug #25494338)

  • X DevAPI: Calling getNodeSession() with an URL string containing SSL parameters caused a CJCommunicationsException. This has been fixed by creating a byte buffer to handle SSL handshake data. (Notice that getNodeSession() has since been consolidated into getSession().) (Bug #23597281)

  • X DevAPI: Concurrent asynchronous operations resulted in hangs, null pointer exceptions, or other unexpected exceptions. This has been fixed by correcting a number of problems with the SerializingBufferWriter and by limiting the number of buffers sent with a gathering write. (Bug #23510958)

  • X DevAPI: When a thread failed to make a connection to the server using the X Protocol, the client application hung. A new connection property, xdevapi.asyncResponseTimeout (default value is 300s), now provides a duration beyond which the attempt to connect timeouts, and a proper error is then thrown. See description for the new option in Configuration Properties for details. (Bug #22972057)

  • Connector/J failed a number of regression tests in the testsuite related to geographic information system (GIS) functions because of changes to GIS support by the MySQL server. The fix corrects the tests. (Bug #26239946, Bug #26140577)

  • Attempts to connect to a server started with collation utf8mb4_de_pb_0900_ai_ci resulted in null pointer exceptions. (Bug #26090721)

  • Configuration templates named by the connection property useConfigs were not recognized by Connector/J. (Bug #25757019, Bug #85555)

  • A NullPointerException was returned when getDate(), getTime(), or getTimestamp() was called with a null Calendar. This fix makes Connector/J throw an SQLException in the case. (Bug #25650305)

  • An ArrayIndexOutOfBoundsException was thrown when a server-side prepared statement was used and there was a NULL in a BLOB, TEXT, or JSON type column in the ResultSet. (Bug #25215008, Bug #84084)