-
Notifications
You must be signed in to change notification settings - Fork 7.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mysql 8.0.15 和 canal 1.1.2 版本 同步数据总是error "Invalid charset id: 255" #1662
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
environment
Issue Description
发现同步数据时总是提示:
Caused by: java.lang.IllegalArgumentException: Invalid charset id: 255
at com.taobao.tddl.dbsync.binlog.CharsetConversion.getEntry(CharsetConversion.java:41)
at com.taobao.tddl.dbsync.binlog.CharsetConversion.getJavaCharset(CharsetConversion.java:299)
at com.taobao.tddl.dbsync.binlog.event.QueryLogEvent.(QueryLogEvent.java:503)
at com.taobao.tddl.dbsync.binlog.LogDecoder.decode(LogDecoder.java:168)
at com.taobao.tddl.dbsync.binlog.LogDecoder.decode(LogDecoder.java:111)
at com.alibaba.otter.canal.parse.inbound.mysql.MysqlMultiStageCoprocessor$SimpleParserStage.onEvent(MysqlMultiStageCoprocessor.java:264)
at com.alibaba.otter.canal.parse.inbound.mysql.MysqlMultiStageCoprocessor$SimpleParserStage.onEvent(MysqlMultiStageCoprocessor.java:246)
at com.lmax.disruptor.BatchEventProcessor.processEvents(BatchEventProcessor.java:168)
at com.lmax.disruptor.BatchEventProcessor.run(BatchEventProcessor.java:125)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
查看com.taobao.tddl.dbsync.binlog.CharsetConversion类下的所有charsetId
范围是1~243对应mysql数据库的Collections表
254单独配置为utf-8
我尝试修改数据库,表和字段的charset的配置为utf-8,客户端连接配置也是utf-8
但是clientCharset = buffer.getUint16();依然返回255.
代码如下:
com.taobao.tddl.dbsync.binlog.event.QueryLogEvent.unpackVariables(line:630)
clientCharset = buffer.getUint16();
这是否是我的配置问题?
Steps to reproduce
Expected behaviour
Actual behaviour
The text was updated successfully, but these errors were encountered: