-
Bug
-
Resolution: Done
-
Major
-
1.0.3.Final, 1.1.0.Final, 1.1.1.Final
-
None
Recently we started using json fields in our MySQL database. Sometimes when we did a migration errors appeared in the log and the connector crashed, but other times no problem occures.
I think that the root cause is the algorithm=instant parameter. When it's present, the connector crashes, when not, it works without a problem.
The error:
2020-05-12 08:06:09,581 ERROR MySQL|db|binlog Error during binlog processing. Last offset stored = null, binlog reader near position = mysql-bin-changelog.036002/2755399 [io.debezium.connector.mysql.BinlogReader] 2020-05-12 08:06:09,581 ERROR MySQL|db|binlog Failed due to error: Error processing binlog event [io.debezium.connector.mysql.BinlogReader] org.apache.kafka.connect.errors.ConnectException: no viable alternative at input 'ALTER TABLE `action_tokens` ADD COLUMN `params` JSON DEFAULT NULL, algorithm=instant' at io.debezium.connector.mysql.AbstractReader.wrap(AbstractReader.java:230) at io.debezium.connector.mysql.AbstractReader.failed(AbstractReader.java:207) at io.debezium.connector.mysql.BinlogReader.handleEvent(BinlogReader.java:536) at com.github.shyiko.mysql.binlog.BinaryLogClient.notifyEventListeners(BinaryLogClient.java:1095) at com.github.shyiko.mysql.binlog.BinaryLogClient.listenForEventPackets(BinaryLogClient.java:943) at com.github.shyiko.mysql.binlog.BinaryLogClient.connect(BinaryLogClient.java:580) at com.github.shyiko.mysql.binlog.BinaryLogClient$7.run(BinaryLogClient.java:825) at java.base/java.lang.Thread.run(Thread.java:834) Caused by: io.debezium.text.ParsingException: no viable alternative at input 'ALTER TABLE `action_tokens` ADD COLUMN `params` JSON DEFAULT NULL, algorithm=instant' at io.debezium.antlr.ParsingErrorListener.syntaxError(ParsingErrorListener.java:40) at org.antlr.v4.runtime.ProxyErrorListener.syntaxError(ProxyErrorListener.java:41) at org.antlr.v4.runtime.Parser.notifyErrorListeners(Parser.java:544) at org.antlr.v4.runtime.DefaultErrorStrategy.reportNoViableAlternative(DefaultErrorStrategy.java:310) at org.antlr.v4.runtime.DefaultErrorStrategy.reportError(DefaultErrorStrategy.java:136) at io.debezium.ddl.parser.mysql.generated.MySqlParser.sqlStatements(MySqlParser.java:1121) at io.debezium.ddl.parser.mysql.generated.MySqlParser.root(MySqlParser.java:849) at io.debezium.connector.mysql.antlr.MySqlAntlrDdlParser.parseTree(MySqlAntlrDdlParser.java:68) at io.debezium.connector.mysql.antlr.MySqlAntlrDdlParser.parseTree(MySqlAntlrDdlParser.java:41) at io.debezium.antlr.AntlrDdlParser.parse(AntlrDdlParser.java:80) at io.debezium.connector.mysql.MySqlSchema.applyDdl(MySqlSchema.java:308) at io.debezium.connector.mysql.BinlogReader.handleQueryEvent(BinlogReader.java:729) at io.debezium.connector.mysql.BinlogReader.handleEvent(BinlogReader.java:519) ... 5 more Caused by: org.antlr.v4.runtime.NoViableAltException at org.antlr.v4.runtime.atn.ParserATNSimulator.noViableAlt(ParserATNSimulator.java:2026) at org.antlr.v4.runtime.atn.ParserATNSimulator.execATN(ParserATNSimulator.java:467) at org.antlr.v4.runtime.atn.ParserATNSimulator.adaptivePredict(ParserATNSimulator.java:393) at io.debezium.ddl.parser.mysql.generated.MySqlParser.sqlStatements(MySqlParser.java:923) ... 12 more 2020-05-12 08:06:09,585 INFO MySQL|db|binlog Error processing binlog event, and propagating to Kafka Connect so it stops this connector. Future binlog events read before connector is shutdown will be ignored. [io.debezium.connector.mysql.BinlogReader]
- is related to
-
DBZ-2071 Synchronize MySQL and Oracle grammars with upstream
- Open