rusuly / MySqlCdc

MySQL/MariaDB binlog replication client for .NET

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TableMetadata.ColumnNames is null

a34546 opened this issue · comments

我想获取TableMetadata.ColumnNames,但是它一是null,是我使用的不对吗?
image

以下是我启动mysql容器和配置:

[mysqld]
server_id= 1
log-bin=/var/lib/mysql/mysql-bin
expire_logs_days=30
character-set-server=utf8mb4
binlog_format=row
binlog_row_metadata = full
binlog_row_image = full
binlog_rows_query_log_events = on

docker run -p 3306:3306 --name mysql8 -v /home/mysql8/mysqld.cnf:/etc/mysql/mysql.conf.d/mysqld.cnf -v /home/mysql8/conf:/etc/mysql/conf.d -v /home/mysql8/logs:/logs -v /home/mysql8/data:/var/lib/mysql -e MYSQL_ROOT_PASSWORD=123.abc -d mysql:latest

Hi, this should work with the binlog_row_metadata=FULL setting.
See the docs.
Make sure you restarted MySQL instance after updating the setting.
Also note that this setting is applied to the newly appended events to binlog.

谢谢,我已经解决了,之前用最新的mysql镜像,修改配置,重启实例,一直不能正常显示columnNames,不清楚是哪里出现了问题。
现在换了个mysql8.0.1镜像重新部署,现在可以显示正常columnNames了