Class MySqlConnectorIT

    • Constructor Detail

      • MySqlConnectorIT

        public MySqlConnectorIT()
    • Method Detail

      • beforeEach

        public void beforeEach()
      • afterEach

        public void afterEach()
      • shouldNotStartWithInvalidConfiguration

        public void shouldNotStartWithInvalidConfiguration()
        Verifies that the connector doesn't run with an invalid configuration. This does not actually connect to the MySQL server.
      • shouldFailToValidateInvalidConfiguration

        public void shouldFailToValidateInvalidConfiguration()
      • shouldValidateValidConfigurationWithSSL

        public void shouldValidateValidConfigurationWithSSL()
      • shouldValidateAcceptableConfiguration

        public void shouldValidateAcceptableConfiguration()
      • shouldValidateLockingModeNoneWithValidSnapshotModeConfiguration

        @FixFor("DBZ-639")
        public void shouldValidateLockingModeNoneWithValidSnapshotModeConfiguration()
        Validates that SNAPSHOT_LOCKING_MODE 'none' is valid with all snapshot modes
      • getPKUpdateNewKeyHeader

        private Optional<org.apache.kafka.connect.header.Header> getPKUpdateNewKeyHeader​(org.apache.kafka.connect.source.SourceRecord record)
      • getPKUpdateOldKeyHeader

        private Optional<org.apache.kafka.connect.header.Header> getPKUpdateOldKeyHeader​(org.apache.kafka.connect.source.SourceRecord record)
      • getHeaderField

        private Optional<org.apache.kafka.connect.header.Header> getHeaderField​(org.apache.kafka.connect.source.SourceRecord record,
                                                                                String fieldName)
      • getAfter

        private org.apache.kafka.connect.data.Struct getAfter​(org.apache.kafka.connect.source.SourceRecord record)
      • shouldEmitTombstoneOnDeleteByDefault

        @FixFor("DBZ-582")
        public void shouldEmitTombstoneOnDeleteByDefault()
                                                  throws Exception
        Throws:
        Exception
      • shouldEmitNoTombstoneOnDelete

        @FixFor("DBZ-582")
        public void shouldEmitNoTombstoneOnDelete()
                                           throws Exception
        Throws:
        Exception
      • shouldNotParseQueryIfServerOptionDisabled

        @FixFor("DBZ-706")
        public void shouldNotParseQueryIfServerOptionDisabled()
                                                       throws Exception
        This test case validates that if you disable MySQL option binlog_rows_query_log_events, then the original SQL statement for an INSERT statement is NOT parsed into the resulting event.
        Throws:
        Exception
      • shouldNotParseQueryIfConnectorNotConfiguredTo

        @FixFor("DBZ-706")
        public void shouldNotParseQueryIfConnectorNotConfiguredTo()
                                                           throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, but configure the connector to NOT include the query, it will not be included in the event.
        Throws:
        Exception
      • shouldParseQueryIfAvailableAndConnectorOptionEnabled

        @FixFor("DBZ-706")
        public void shouldParseQueryIfAvailableAndConnectorOptionEnabled()
                                                                  throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then the original SQL statement for an INSERT statement is parsed into the resulting event.
        Throws:
        Exception
      • parseMultipleInsertStatements

        @FixFor("DBZ-706")
        public void parseMultipleInsertStatements()
                                           throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then the issue multiple INSERTs, the appropriate SQL statements are parsed into the resulting events.
        Throws:
        Exception
      • parseMultipleRowInsertStatement

        @FixFor("DBZ-706")
        public void parseMultipleRowInsertStatement()
                                             throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then the issue single multi-row INSERT, the appropriate SQL statements are parsed into the resulting events.
        Throws:
        Exception
      • parseDeleteQuery

        @FixFor("DBZ-706")
        public void parseDeleteQuery()
                              throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then the original SQL statement for a DELETE over a single row is parsed into the resulting event.
        Throws:
        Exception
      • parseMultiRowDeleteQuery

        @FixFor("DBZ-706")
        public void parseMultiRowDeleteQuery()
                                      throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then issue a multi-row DELETE, the resulting events get the original SQL statement.
        Throws:
        Exception
      • parseUpdateQuery

        @FixFor("DBZ-706")
        public void parseUpdateQuery()
                              throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then the original SQL statement for an UPDATE over a single row is parsed into the resulting event.
        Throws:
        Exception
      • parseMultiRowUpdateQuery

        @FixFor("DBZ-706")
        public void parseMultiRowUpdateQuery()
                                      throws Exception
        This test case validates that if you enable MySQL option binlog_rows_query_log_events, then the original SQL statement for an UPDATE over a single row is parsed into the resulting event.
        Throws:
        Exception
      • shouldFailToValidateAdaptivePrecisionMode

        @FixFor("DBZ-1234")
        public void shouldFailToValidateAdaptivePrecisionMode()
                                                       throws InterruptedException
        Specifying the adaptive time.precision.mode is no longer valid and a configuration validation problem should be reported when that configuration option is used.
        Throws:
        InterruptedException
      • testEmptySchemaLogWarningWithDatabaseWhitelist

        @FixFor("DBZ-1242")
        public void testEmptySchemaLogWarningWithDatabaseWhitelist()
                                                            throws Exception
        Throws:
        Exception
      • testNoEmptySchemaLogWarningWithDatabaseWhitelist

        @FixFor("DBZ-1242")
        public void testNoEmptySchemaLogWarningWithDatabaseWhitelist()
                                                              throws Exception
        Throws:
        Exception
      • testEmptySchemaWarningWithTableWhitelist

        @FixFor("DBZ-1242")
        public void testEmptySchemaWarningWithTableWhitelist()
                                                      throws Exception
        Throws:
        Exception
      • testNoEmptySchemaWarningWithTableWhitelist

        @FixFor("DBZ-1242")
        public void testNoEmptySchemaWarningWithTableWhitelist()
                                                        throws Exception
        Throws:
        Exception
      • shouldOutputRecordsInCloudEventsFormat

        @FixFor("DBZ-1292")
        public void shouldOutputRecordsInCloudEventsFormat()
                                                    throws Exception
        Throws:
        Exception
      • shouldEmitHeadersOnPrimaryKeyUpdate

        @FixFor("DBZ-1531")
        public void shouldEmitHeadersOnPrimaryKeyUpdate()
                                                 throws Exception
        Throws:
        Exception
      • shouldEmitNoEventsForSkippedCreateOperations

        @FixFor("DBZ-1895")
        public void shouldEmitNoEventsForSkippedCreateOperations()
                                                          throws Exception
        Throws:
        Exception
      • shouldEmitNoEventsForSkippedUpdateAndDeleteOperations

        @FixFor("DBZ-1895")
        public void shouldEmitNoEventsForSkippedUpdateAndDeleteOperations()
                                                                   throws Exception
        Throws:
        Exception
      • testNoEmptySchemaLogWarningWithSnapshotNever

        @FixFor("DBZ-1344")
        public void testNoEmptySchemaLogWarningWithSnapshotNever()
                                                          throws Exception
        Throws:
        Exception