This section summarizes what has been added to, deprecated in, and removed from MySQL 8.2. A companion section lists MySQL server options and variables that have been added, deprecated, or removed in MySQL 8.2; see Section 1.6, “Server and Status Variables and Options Added, Deprecated, or Removed in MySQL 8.2”.
If you are upgrading directly from MySQL 8.0 to MySQL 8.2, you should also consult Section 1.4, “What Is New in MySQL 8.1”, which lists changes in MySQL 8.1 relative to MySQL 8.0.
The following features have been added to MySQL 8.2:
Additions to server startup and shutdown messages. Added the following types of messages to the server startup and shutdown processes as noted in this list:
Start and end messages for server initialization when the server is started with
--initialize-insecure; these are in addition to and distinct from those shown during normal server startup and shutdown.
Start and end messages for
Start and end messages for init file execution during server initialization.
Start and end messages for for execution of compiled-in statements during server initialization.
Start and end mesages for crash recovery during server startup (if crash recovery occurs).
Start and end messages for initialization of dynamic plugins during server startup.
Start and end messages for compoenents initialization step (apparent during server startup).
Messages for shutdown of replica threads, as well as graceful and forceful shutdown of connection threads, during server shutdown.
Start and end messages for shutdown of plugins and components during server shutdown.
Exit code (return value) information with shutdown messages during initialization or server shutdown and end)
In addition, if the server was built using
WITH_SYSTEMD, the server now includes every systemd message in the error log.
Hash table optimization for set operations. MySQL 8.2 improves performance of statements using the set operations
INTERSECTby means of a new hash table optimization which is enabled automatically for such statements, and controlled by setting the
hash_set_operationsoptimizer switch; to disable this optimization and cause the optimizer to used the old temporary table optimization from previous versions of MySQL, set this flag to
The amount of memory allocated for this optimization can be controlled by setting the value of the
set_operations_buffer_sizeserver system variable; increasing the buffer size can further improve execution times of some statements using these operations.
See Section 8.9.2, “Switchable Optimizations”, for more information.
MySQL Enterprise Audit. Added the
audit_log_filter_uninstall.sqlscript to simplify removing MySQL Enterprise Audit.
Pluggable authentication. Added support for authentication to MySQL Server using devices such as smart cards, security keys, and biometric readers in a WebAuthn context. The new WebAuthn authentication method is based on the FIDO and FIDO2 standards. It uses a pair of plugins,
authentication_webauthnon the server side and
authentication_webauthn_clienton the client side. The server-side WebAuthn authentication plugin is included only in MySQL Enterprise Edition distributions.
MySQL Enterprise Firewall. These enhancements were added:
MySQL Enterprise Firewall now permits its memory cache to be reloaded periodically with data stored in the firewall tables. The
mysql_firewall_reload_interval_secondssystem variable sets the periodic-reload schedule to use at runtime or it disables reloads by default. Previous implementations reloaded the cache only at server startup or when the server-side plugin was reinstalled.
mysql_firewall_databaseserver system variable to enable storing internal tables, functions, and stored procedures in a custom schema.
uninstall_firewall.sqlscript to simplify removing an installed firewall.
MySQL Privileges. Added the
SET_ANY_DEFINERprivilege for definer object creation and the
ALLOW_NONEXISTENT_DEFINERprivilege for orphan object protection. Together these privileges coexist with the deprecated
EXPLAIN FOR SCHEMA. Added a
FOR SCHEMAoption to the
EXPLAINstatement. The syntax is as shown here, where
stmtis an explainable statement:
EXPLAIN [options] FOR SCHEMA schema_name stmt
stmtto be run as if in the named schema.
FOR DATABASEis also supported as a synonym.
This option is not compatible with
See Obtaining Execution Plan Information, for more information.
mysql_native_passwordplugin, which was deprecated previously, now is no longer mandatory and can be disabled at server startup.
If the server-side
mysql_native_passwordauthentication method is disabled, older client accounts that use the client-side plugin (prior to MySQL 5.5 and possibly MySQL 5.6) are no longer able to connect and the server writes an “Access denied” message to the error log. These connections are no longer possible because, although the protocol remains compatible, the authentication method supported by the client is missing.
Replication: SQL_AFTER_GTIDS and MTA. The
START REPLICAstatement option
SQL_AFTER_GTIDSis now compatible with the multi-threaded applier. (Previously, when MTA was enabled and the user attempted to use this option, the statement raised the warning
ER_MTS_FEATURE_IS_NOT_SUPPORTED, and the replica was switched to single-threaded mode.) This means that a replica which needs to catch up with missing transactions can now do so without losing the performance advantage from multithreading.
For more information, see Section 22.214.171.124, “START REPLICA Statement”, as well as the documentation for the
replica_parallel_workerssystem variable. See also Section 126.96.36.199, “Monitoring Replication Applier Worker Threads”, and Section 23.7.11, “NDB Cluster Replication Using the Multithreaded Applier”.
Replication terminology backwards compatibility. This release adds the
--output-as-versionoption for mysqldump. This option allows you to create a dump from a MySQL 8.2 server that is compatible with older versions of MySQL; its value, one of those listed here, determines the compatibility of replication terminology used in the dump:
SERVER: Gets the version of the server and uses the latest versions of replication statements and variable names compatible with that MySQL version.
BEFORE_8_2_0: Output is compatible with MySQL servers running versions 8.0.23 through 8.1.0, inclusive.
BEFORE_8_0_23: Output is compatible with MySQL servers running versions prior to 8.0.23.
See the description of this option for more information.
In addition a new value is added to those already allowed for the
BEFORE_8_2_0causes the server to print
DISABLE ON SLAVE(now deprecated) instead of
DISABLE ON REPLICAin the output of
SHOW CREATE EVENT. The existing value
BEFORE_8_0_26now also has this effect in addition to those it already had previously.
The following features are deprecated in MySQL 8.2 and may be removed in a future series. Where alternatives are shown, applications should be updated to use them.
For applications that use features deprecated in MySQL 8.2 that have been removed in a higher MySQL series, statements may fail when replicated from a MySQL 8.2 source to a higher-series replica, or may have different effects on source and replica. To avoid such problems, applications that use features deprecated in 8.2 should be revised to avoid them and use alternatives when possible.
Wildcard characters in database grants. The use of the characters
_as wildcards in database grants is deprecated in MySQL 8.2.0 and later MySQL Innovation releases. You should expect for the wildcard functionality to removed in a future MySQL release and for these characters always to be treated as literals, as they are already whenever the value of the
partial_revokesserver system variable is
In addition, the treatment of
%by the server as a synonym for
localhostwhen checking privileges is now also deprecated as of MySQL 8.2.0 and thus subject to removal in a future version of MySQL.
old and new (server system variables). The
newserver system variables and related server options are deprecated in MySQL 8.2.0 and later Innovation releases, and a warning is now issued whenever either of these variables is set or read. Because these variables are destined for removal in a future version of MySQL, applications which depend on them should begin migration away from them as soon as possible.
--character-set-client-handshake option. The
--character-set-client-handshakeserver option, originally intended for use with upgrades from very old versions of MySQL, is now deprecated in MySQL 8.2.0 and later MySQL Innovation releases, where a warning is issued whenever it is used. You should expect this option to be removed in a future version of MySQL; applications depending on this option should begin migration away from it as soon as possible.
binlog_transaction_dependency_trackingserver system variable is deprecated in MySQL 8.2.0 and later Innovation releases, and is subject to removal in a future version of MySQL. Referencing this variable or the equivalent mysqld startup option
--binlog-transaction-dependency-trackingnow triggers a warning. There are no plans to replace this variable or its functionality, which is expected later to be made internal to the server.
Replication SQL. MySQL 8.2 continues work begun in previous releases to update terminology used in SQL statements relating to MySQL Replication. This release deprecates the following statements, listed with their replacements:
As part of this work, the
DISABLE ON SLAVEoption for
ALTER EVENTis now deprecated, and is superseded by
DISABLE ON REPLICA. The corresponding term
SLAVESIDE_DISABLEDis also now deprecated,and no longer used in event descriptions such as in the Information Schema
REPLICA_SIDE_DISABLEDis now shown instead.
In addition, the
Com_show_master_statussystem status variable is renamed to
Com_show_binary_log_status. The previous name is still supported for backwards compatibility, but is now deprecated and subject to removal in a future version of MySQL.
SET_USER_ID privilege. The
SET_USER_IDprivilege is deprecated and is subject to removal in a future version of MySQL. When
SET_USER_IDis granted using
GRANT, a SQL warning informs you of the deprecation status. It is now superseded by these new privileges:
The following items are obsolete and have been removed in MySQL 8.2. Where alternatives are shown, applications should be updated to use them.
For MySQL 8.1 applications that use features removed in MySQL 8.2, statements may fail when replicated from a MySQL 8.1 source to a MySQL 8.2 replica, or may have different effects on source and replica. To avoid such problems, applications that use features removed in MySQL 8.2 should be revised to avoid them and use alternatives when possible.
WAIT_UNTIL_SQL_THREAD_AFTER_GTIDS() function. The
WAIT_UNTIL_SQL_THREAD_AFTER_GTIDS()SQL function was deprecated in MySQL 8.0, and is no longer supported in MySQL 8.2. Attempting to invoke this function now causes a syntax error.
WAIT_UNTIL_SQL_THREAD_AFTER_GTIDS(), it is recommended that you use
WAIT_FOR_EXECUTED_GTID_SET(), which allows you to wait for specific GTIDS. This works regardless of the replication channel or the user client through which the specified transactions arrive on the server.
expire_logs_days system variable. The
expire_logs_daysserver system variable, deprecated in MySQL 8.0, has been removed. Attempting to get or set this variable at runtime, or to start mysqld with the equivalent option (
--expire-logs-days), now results in an error.
In place of
binlog_expire_logs_seconds, which allows you to specify expiration periods other than (only) in an integral number of days.
--abort-slave-event-count and --disconnect-slave-event-count server options. The MySQL server startup options
--disconnect-slave-event-count, formerly used in testing, were deprecated in MySQL 8.0, and have been removed in this release. Attempting to start mysqld with either of these options now results in an error.