Canal Fails to Parse Binlogs
Scenario
An error occurred when Canal parsed binlogs, interrupting binlog collection. The error message is as follows:
com.alibaba.otter.canal.parse.exception.CanalParseException: java.lang.NumberFormatException:- Caused by: java.lang.NumberFormatException: - at com.alibaba.fastsql.sql.parser.Lexer.integerValue(Lexer.java:2454)
Possible Causes
Check whether the value of binlog_rows_query_log_events of your instance is set to 1 or ON.
- Canal supports only subscriptions to binlogs in row format.
- When the value of binlog_rows_query_log_events is set to 1 or ON, Rows_query events are generated in binlogs. These events are not in row format. In certain scenarios, blank topics may occur in Canal, resulting in a binlog parsing failure.
Solution
Change the value of binlog_rows_query_log_events to OFF and restart the interrupted Canal task.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.