Uploaded image for project: 'Debezium'
  1. Debezium
  2. DBZ-646

io.debezium.text.ParsingException for TokuDB table

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major Major
    • 0.7.5
    • None
    • mysql-connector
    • None

      I want to use Debezium to replicate MySQL TokuDB table.
      When running connector I'm getting following exception.

      Caused by: io.debezium.text.ParsingException: Failed to parse statement 'CREATE TABLE `table` (
      /** table def **/
      ) ENGINE=TokuDB AUTO_INCREMENT=123 DEFAULT CHARSET=utf8 `compression`=tokudb_zlib'
      	at io.debezium.relational.ddl.DdlParser.parse(DdlParser.java:292)
      	at io.debezium.relational.ddl.DdlParser.parse(DdlParser.java:267)
      	at io.debezium.connector.mysql.MySqlSchema.applyDdl(MySqlSchema.java:322)
      	at io.debezium.connector.mysql.SnapshotReader.lambda$execute$9(SnapshotReader.java:427)
      	at io.debezium.jdbc.JdbcConnection.query(JdbcConnection.java:392)
      	at io.debezium.jdbc.JdbcConnection.query(JdbcConnection.java:347)
      	at io.debezium.connector.mysql.SnapshotReader.execute(SnapshotReader.java:425)
      	... 3 more
      Caused by: io.debezium.text.ParsingException: Expecting 8|16 at line 35, column 77 but found 'tokudb_zlib': =utf8 `compression`= ===>> tokudb_zlib
      	at io.debezium.text.TokenStream.consumeAnyOf(TokenStream.java:826)
      	at io.debezium.relational.ddl.DdlParser.consumeQuotedString(DdlParser.java:637)
      	at io.debezium.connector.mysql.MySqlDdlParser.parseTableOption(MySqlDdlParser.java:442)
      	at io.debezium.connector.mysql.MySqlDdlParser.parseTableOptions(MySqlDdlParser.java:410)
      	at io.debezium.connector.mysql.MySqlDdlParser.parseCreateTable(MySqlDdlParser.java:388)
      	at io.debezium.connector.mysql.MySqlDdlParser.parseCreate(MySqlDdlParser.java:289)
      	at io.debezium.connector.mysql.MySqlDdlParser.parseNextStatement(MySqlDdlParser.java:160)
      	at io.debezium.relational.ddl.DdlParser.parse(DdlParser.java:286)
      	... 9 more
      

            [DBZ-646] io.debezium.text.ParsingException for TokuDB table

            Released

            Jiri Pechanec added a comment - Released

            The PR looks good, thanks, maver1ckpl_jira!

            Gunnar Morling added a comment - The PR looks good, thanks, maver1ckpl_jira !

            gunnar.morling
            I fixed parser. Could you check this patch ?
            https://github.com/debezium/debezium/pull/478

            Maciej Bryński (Inactive) added a comment - gunnar.morling I fixed parser. Could you check this patch ? https://github.com/debezium/debezium/pull/478

            I can do the tests in my environment.
            Patch will be more than welcome
            (I can also provide full CREATE TABLE stmt)

            Maciej Bryński (Inactive) added a comment - - edited I can do the tests in my environment. Patch will be more than welcome (I can also provide full CREATE TABLE stmt)

            Hi, we can adjust the parser to fix this, but note we don't do any testing with TokuDB. For this to work, the binlog format must be the same as with other engines (not sure whether the binlog format is affected by the engine, just mentioning it, so you're aware of it).

            Gunnar Morling added a comment - Hi, we can adjust the parser to fix this, but note we don't do any testing with TokuDB. For this to work, the binlog format must be the same as with other engines (not sure whether the binlog format is affected by the engine, just mentioning it, so you're aware of it).

              Unassigned Unassigned
              maver1ckpl_jira Maciej Bryński (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: