NDB Client Programs: Two options are added for the ndb_blob_tool utility, to enable it to detect missing blob parts for which inline parts exist, and to replace these with placeholder blob parts (consisting of space characters) of the correct length. To check whether there are missing blob parts, use the ndb_blob_tool
--check-missing
option. To replace with placeholders any blob parts which are missing, use the program's--add-missing
option, also added in this release. (Bug #28583971)NDB Client Programs: Removed a dependency from the ndb_waiter and ndb_show_tables utility programs on the
NDBT
library. This library, used inNDB
development for testing, is not required for normal use. The visible effect for users from this change is that these programs no longer printNDBT_ProgramExit -
following completion of a run. Applications that depend upon this behavior should be updated to reflect this change when upgrading to this release. (WL #13727, WL #13728)status
MySQL NDB ClusterJ: The unused
antlr3
plugin has been removed from the ClusterJpom
file. (Bug #29931625)MySQL NDB ClusterJ: The minimum Java version ClusterJ supports for MySQL NDB Cluster 8.0 is now Java 8. (Bug #29931625)
-
MySQL NDB ClusterJ: A few Java APIs used by ClusterJ are now deprecated in recent Java versions. These adjustments have been made to ClusterJ:
Replaced all
Class.newInstance()
calls withClass.getDeclaredConstructor().newInstance()
calls. Also updated the exception handling and the test cases wherever required.All the
Number
classes' constructors that instantiate an object from aString
or a primitive type are deprecated. Replaced all such deprecated instantiation calls with the correspondingvalueOf()
method calls.The
Proxy.getProxyClass()
is now deprecated. TheDomainTypeHandlerImpl
class now directly creates a new instance using theProxy.newProxyInstance()
method; all references to theProxy
class and its constructors are removed from theDomainTypeHandlerImpl
class.SessionFactoryImpl
class now uses the interfaces underlying the proxy object to identify the domain class rather than using the Proxy class. Also updatedDomainTypeHandlerFactoryTest
.The
finalize()
method is now deprecated. This patch does not change the overriding finalize() methods, but just suppresses the warnings on them. This deprecation will be handled separately in a later patch.Updated the CMake configuration to treat deprecation warnings as errors when compiling ClusterJ.
(Bug #29931625)
-
It now possible to consolidate data from separate instances of NDB Cluster into a single target NDB Cluster when the original datasets all use the same schema. This is supported when using backups created using
START BACKUP
in ndb_mgm and restoring them with ndb_restore, using the--remap-column
option implemented in this release (along with--restore-data
and possibly other options).--remap-column
can be employed to handle cases of overlapping primary, unique, or both sorts of key values between source clusters, and you need to make sure that they do not overlap in the target cluster. This can also be done to preserve other relationships between tables.When used together with
--restore-data
, the new option applies a function to the value of the indicated column. The value set for this option is a string of the format
, whose components are listed here:db
.tbl
.col
:fn
:args
db
: Database name, after performing any renames.tbl
: Table name.col
: Name of the column to be updated. This column's type must be one ofINT
orBIGINT
, and can optionally beUNSIGNED
.fn
: Function name; currently, the only supported name isoffset
.args
: The size of the offset to be added to the column value byoffset
. The range of the argument is that of the signed variant of the column's type; thus, negative offsets are supported.
You can use
--remap-column
for updating multiple columns of the same table and different columns of different tables, as well as combinations of multiple tables and columns. Different offset values can be employed for different columns of the same table.As part of this work, two new options are also added to ndb_desc in this release:
--auto-inc
(short form-a
): Includes the next auto-increment value in the output, if the table has anAUTO_INCREMENT
column.--context
(short form-x
): Provides extra information about the table, including the schema, database name, table name, and internal ID.
These options may be useful for obtaining information about
NDB
tables when planning a merge, particularly in situations where the mysql client may not be readily available.For more information, see the descriptions for
--remap-column
,--auto-inc
, and--context
. (Bug #30383950, WL #11796) -
ndb_restore now supports different primary key definitions for source and target tables when restoring from an
NDB
native backup, using the--allow-pk-changes
option introduced in this release. Both increasing and decreasing the number of columns making up the original primary key are supported. This may be useful when it is necessary to accommodate schema version changes while restoring data, or when doing so is more efficient or less time-consuming than performingALTER TABLE
statements involving primary key changes on a great many tables following the restore operation.When extending a primary key with additional columns, any columns added must not be nullable, and any values stored in any such columns must not change while the backup is being taken. Changes in the values of any such column while trying to add it to the table's primary key causes the restore operation to fail. Due to the fact that some applications set the values of all columns when updating a row even if the values of one or more of the columns does not change, it is possible to override this behavior by using the
--ignore-extended-pk-updates
option which is also added in this release. If you do this, care must be taken to insure that such column values do not actually change.When removing columns from the table's primary key, it is not necessary that the columns dropped from the primary key remain part of the table afterwards.
For more information, see the description of the
--allow-pk-changes
option in the documentation for ndb_restore. (Bug #26435136, Bug #30383947, Bug #30634010, WL #10730) -
Added the
--ndb-log-fail-terminate
option for mysqld. When used, this causes the SQL node to terminate if it is unable to log all row events. (Bug #21911930)References: See also: Bug #30383919.
MySQL NDB ClusterJ: When a
Date
value was read from a NDB cluster, ClusterJ sometimes extracted the wrong year value from the row. It was because theUtility
class, when unpacking theDate
value, wrongly extracted some extra bits for the year. This patch makes ClusterJ only extract the required bits. (Bug #30600320)MySQL NDB ClusterJ: When the cluster's
NdbOperation::AbortOption
type had the value ofAO_IgnoreOnError
, when there was a read error, ClusterJ took that as the row was missing and returnednull
instead of an exception. This was because withAO_IgnoreOnErro
, theexecute()
method always returns a success code after each transaction, and ClusterJ is supposed to check for any errors in any of the individual operations; however, read operations were not checked by ClusterJ in the case. With this patch, read operations are now checked for errors after query executions, so that a reading error is reported as such. (Bug #30076276)When restoring signed auto-increment columns, ndb_restore incorrectly handled negative values when determining the maximum value included in the data. (Bug #30928710)
When a node ID allocation request failed with NotMaster temporary errors, the node ID allocation was always retried immediately, without regard to the cause of the error. This caused a very high rate of retries, whose effects could be observed as an excessive number of Alloc node id for node
nnn
failed log messages (on the order of 15,000 messages per second). (Bug #30293495)For
NDB
tables having no explicit primary key,NdbReceiverBuffer
could be allocated with too small a size. This was due to the fact that the attribute bitmap sent toNDB
from the data nodes always includes the primary key. The extra space required for hidden primary keys is now taken into consideration in such cases. (Bug #30183466)