Skip to main content

Aliyun ADB MySQL

Applicable EditionsTapData CloudTapData Cloud offers you cloud services that are suitable for scenarios requiring rapid deployment and low initial investment, helping you focus more on business development rather than infrastructure management. Free trial with TapData Cloud.TapData EnterpriseTapData Enterprise can be deployed in your local data center, making it suitable for scenarios with strict requirements on data sensitivity or network isolation. It can serve to build real-time data warehouses, enable real-time data exchange, data migration, and more.TapData CommunityTapData Community is an open-source data integration platform that provides basic data synchronization and transformation capabilities. This helps you quickly explore and implement data integration projects. As your project or business grows, you can seamlessly upgrade to TapData Cloud or TapData Enterprise to access more advanced features and service support.

Please follow the instructions below to successfully add and use Aliyun ADB MySQL database in TapData Cloud.

Supported Versions

Aliyun ADB MySQL 5.0, 5.1, 5.5, 5.6, 5.7, 8.x

Prerequisites (As a Source)

Enable binlog for Aliyun ADB MySQL.

Cascade deletes, such as those generated by the database, are not recorded in the binlog and are therefore not supported.

Create Aliyun ADB MySQL Account

For MySQL 8 and later versions, the encryption method for passwords is different. Please use the corresponding method for the version to set the password; otherwise, incremental synchronization may not work.

3.3.1 For 5.x versions

create user 'username'@'localhost' identified by 'password';

3.3.2 For 8.x versions

-- Create user
create user 'username'@'localhost' identified with mysql_native_password by 'password';
-- Change password
alter user 'username'@'localhost' identified with mysql_native_password by 'password';

Grant Account Permissions

Grant SELECT permission for a specific database:

GRANT SELECT, SHOW VIEW, CREATE ROUTINE, LOCK TABLES ON <DATABASE_NAME>.<TABLE_NAME> TO 'tapdata' IDENTIFIED BY 'password';

Grant global permissions:

GRANT RELOAD, SHOW DATABASES, REPLICATION SLAVE, REPLICATION CLIENT ON *.* TO 'tapdata' IDENTIFIED BY 'password';

Constraint Description

When syncing from Aliyun ADB MySQL to other heterogeneous databases, if the source Aliyun ADB MySQL has table cascade settings, data updates and deletions triggered by such cascades will not be propagated to the target. If you need to build cascade handling capability on the target side, depending on the target, you can achieve this type of data synchronization through triggers or other means.

About Update Events

AliYun ADB MySQL update events cannot update primary keys. Therefore, when writing updates, it's necessary to determine whether the primary key value before and after the update is the same. If they are the same, the primary key needs to be removed for the update. If they are different, the update needs to be split into a delete and an insert operation.