Debezium引擎无法捕获MySQL数据库上的更改

Debezium引擎无法捕获MySQL数据库上的更改,mysql,spring-boot,debezium,Mysql,Spring Boot,Debezium,我有一个SpringBoot应用程序,其中对DebeziumAPI进行了增强,以捕获MySQL数据库中的任何更改 我试图让Debezium引擎Api(v1.1.2)捕获MySQL本地数据库上的任何更改 但是,由于某些原因,当任何变化发生时,嵌入式Debezium无法捕获 有人能帮我吗 这是我的配置代码 import io.debezium.engine.ChangeEvent; import io.debezium.engine.DebeziumEngine; import io.debeziu

我有一个SpringBoot应用程序,其中对DebeziumAPI进行了增强,以捕获MySQL数据库中的任何更改

我试图让Debezium引擎Api(v1.1.2)捕获MySQL本地数据库上的任何更改

但是,由于某些原因,当任何变化发生时,嵌入式Debezium无法捕获

有人能帮我吗

这是我的配置代码

import io.debezium.engine.ChangeEvent;
import io.debezium.engine.DebeziumEngine;
import io.debezium.engine.format.Json;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.io.IOException;
import java.util.Properties;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

@Configuration
public class InstalaCoreDatabaseConnectorConfiguration {

    @Value("${instala.datasource.serverid}")
    private String databaseServerId;

    @Value("${instala.datasource.host}")
    private String databaseHost;

    @Value("${instala.datasource.databasename.core}")
    private String coreDatabaseName;

    @Value("${instala.datasource.port}")
    private String databasePort;

    @Value("${instala.datasource.username}")
    private String databaseUserName;

    @Value("${instala.datasource.password}")
    private String databasePassword;

    private final String[] coreDatabaseWhitelistTables = {
            //"SERVC_ORD_EVNT",
            //"SERVC_ORD_ITEM",
             "test_dev_core.servc_prvdr"
            //"SERVC_PRVDR_AGNT"
    };

    @Bean
    public void coreDatabaseConnector() throws IOException {

        final Properties props = new Properties();
        props.setProperty("name", "instala-core");
        props.setProperty("connector.class", "io.debezium.connector.mysql.MySqlConnector");
        props.setProperty("offset.storage", "org.apache.kafka.connect.storage.FileOffsetBackingStore");
        props.setProperty("offset.storage.file.filename", "/tmp/offsets.dat");
        props.setProperty("offset.flush.interval.ms", "60000");

        /* begin connector properties */
        props.setProperty("database.hostname", databaseHost);
        props.setProperty("database.port", databasePort);
        props.setProperty("database.user", databaseUserName);
        props.setProperty("database.password", databasePassword);
        props.setProperty("database.server.id", databaseServerId);
        props.setProperty("database.server.name", "instalacore");

        props.setProperty("database.history", "io.debezium.relational.history.FileDatabaseHistory");
        props.setProperty("database.history.file.filename", "/tmp/dbhistory.dat");
    
        props.setProperty("table.whitelist", String.join(",", coreDatabaseWhitelistTables));

        // Create the engine with this configuration ...
        try (DebeziumEngine<ChangeEvent<String, String>> engine = DebeziumEngine.create(Json.class)
                .using(props)
                .notifying(record -> {
                    System.out.println(record);
                }).build()
        ) {
            Executors.newSingleThreadExecutor().execute(engine);

            // Run the engine asynchronously ...
            ExecutorService executor = Executors.newSingleThreadExecutor();
            executor.execute(engine);

            // Do something else or wait for a signal or an event
        }

    }
}
这是我的Spring启动应用程序日志

2020-06-25 17:08:34.613  INFO 2625 --- [           main] com.test.cdc.CDCRelayApplication  : Starting CDCRelayApplication on bruno-Inspiron-7580 with PID 2625 (/var/www/html/cdc-relay/target/classes started by bruno in /var/www/html/cdc-relay)
2020-06-25 17:08:34.615  INFO 2625 --- [           main] com.test.cdc.CDCRelayApplication  : No active profile set, falling back to default profiles: default
2020-06-25 17:08:35.560  INFO 2625 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat initialized with port(s): 8080 (http)
2020-06-25 17:08:35.571  INFO 2625 --- [           main] o.apache.catalina.core.StandardService   : Starting service [Tomcat]
2020-06-25 17:08:35.571  INFO 2625 --- [           main] org.apache.catalina.core.StandardEngine  : Starting Servlet engine: [Apache Tomcat/9.0.27]
2020-06-25 17:08:35.671  INFO 2625 --- [           main] o.a.c.c.C.[Tomcat].[localhost].[/]       : Initializing Spring embedded WebApplicationContext
2020-06-25 17:08:35.671  INFO 2625 --- [           main] o.s.web.context.ContextLoader            : Root WebApplicationContext: initialization completed in 1016 ms
2020-06-25 17:08:35.869  INFO 2625 --- [           main] o.a.k.connect.json.JsonConverterConfig   : JsonConverterConfig values: 
    converter.type = key
    schemas.cache.size = 1000
    schemas.enable = true

2020-06-25 17:08:35.871  INFO 2625 --- [           main] o.a.k.connect.json.JsonConverterConfig   : JsonConverterConfig values: 
    converter.type = value
    schemas.cache.size = 1000
    schemas.enable = false

2020-06-25 17:08:35.875  INFO 2625 --- [           main] i.d.e.EmbeddedEngine$EmbeddedConfig      : EmbeddedConfig values: 
    access.control.allow.methods = 
    access.control.allow.origin = 
    bootstrap.servers = [localhost:9092]
    client.dns.lookup = default
    config.providers = []
    connector.client.config.override.policy = None
    header.converter = class org.apache.kafka.connect.storage.SimpleHeaderConverter
    internal.key.converter = class org.apache.kafka.connect.json.JsonConverter
    internal.value.converter = class org.apache.kafka.connect.json.JsonConverter
    key.converter = class org.apache.kafka.connect.json.JsonConverter
    listeners = null
    metric.reporters = []
    metrics.num.samples = 2
    metrics.recording.level = INFO
    metrics.sample.window.ms = 30000
    offset.flush.interval.ms = 60000
    offset.flush.timeout.ms = 5000
    offset.storage.file.filename = /tmp/offsets.dat
    offset.storage.partitions = null
    offset.storage.replication.factor = null
    offset.storage.topic = 
    plugin.path = null
    rest.advertised.host.name = null
    rest.advertised.listener = null
    rest.advertised.port = null
    rest.extension.classes = []
    rest.host.name = null
    rest.port = 8083
    ssl.client.auth = none
    task.shutdown.graceful.timeout.ms = 5000
    value.converter = class org.apache.kafka.connect.json.JsonConverter

2020-06-25 17:08:35.875  INFO 2625 --- [           main] o.a.kafka.connect.runtime.WorkerConfig   : Worker configuration property 'internal.key.converter' is deprecated and may be removed in an upcoming release. The specified value 'org.apache.kafka.connect.json.JsonConverter' matches the default, so this property can be safely removed from the worker configuration.
2020-06-25 17:08:35.876  INFO 2625 --- [           main] o.a.kafka.connect.runtime.WorkerConfig   : Worker configuration property 'internal.value.converter' is deprecated and may be removed in an upcoming release. The specified value 'org.apache.kafka.connect.json.JsonConverter' matches the default, so this property can be safely removed from the worker configuration.
2020-06-25 17:08:35.878  INFO 2625 --- [           main] o.a.k.connect.json.JsonConverterConfig   : JsonConverterConfig values: 
    converter.type = key
    schemas.cache.size = 1000
    schemas.enable = true

2020-06-25 17:08:35.878  INFO 2625 --- [           main] o.a.k.connect.json.JsonConverterConfig   : JsonConverterConfig values: 
    converter.type = value
    schemas.cache.size = 1000
    schemas.enable = true

2020-06-25 17:08:35.880  INFO 2625 --- [           main] io.debezium.embedded.EmbeddedEngine      : Stopping the embedded engine
2020-06-25 17:08:35.881  INFO 2625 --- [           main] io.debezium.embedded.EmbeddedEngine      : Waiting for PT5M for connector to stop
2020-06-25 17:08:35.884  INFO 2625 --- [pool-2-thread-1] o.a.k.c.storage.FileOffsetBackingStore   : Starting FileOffsetBackingStore with file /tmp/offsets.dat
2020-06-25 17:08:35.920  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      : Starting MySqlConnectorTask with configuration:
2020-06-25 17:08:35.922  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    connector.class = io.debezium.connector.mysql.MySqlConnector
2020-06-25 17:08:35.922  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.history.file.filename = /tmp/dbhistory.dat
2020-06-25 17:08:35.922  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.user = admin
2020-06-25 17:08:35.922  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    offset.storage = org.apache.kafka.connect.storage.FileOffsetBackingStore
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.server.id = 1
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.server.name = instalacore
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.port = 3306
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    table.whitelist = test_dev_core.servc_prvdr
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    offset.flush.interval.ms = 60000
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    offset.storage.file.filename = /tmp/offsets.dat
2020-06-25 17:08:35.923  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.hostname = localhost
2020-06-25 17:08:35.924  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.password = ********
2020-06-25 17:08:35.924  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    name = instala-core
2020-06-25 17:08:35.924  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      :    database.history = io.debezium.relational.history.FileDatabaseHistory
2020-06-25 17:08:36.194  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.MySqlConnectorTask   : Found no existing offset, so preparing to perform a snapshot
2020-06-25 17:08:36.222  INFO 2625 --- [pool-2-thread-1] io.debezium.util.Threads                 : Requested thread factory for connector MySqlConnector, id = instalacore named = binlog-client
2020-06-25 17:08:36.231  INFO 2625 --- [pool-2-thread-1] io.debezium.util.Threads                 : Requested thread factory for connector MySqlConnector, id = instalacore named = snapshot
2020-06-25 17:08:36.231  INFO 2625 --- [pool-2-thread-1] io.debezium.util.Threads                 : Creating thread debezium-mysqlconnector-instalacore-snapshot
2020-06-25 17:08:36.232  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       : Starting snapshot for jdbc:mysql://localhost:3306/?useInformationSchema=true&nullCatalogMeansCurrent=false&useSSL=false&useUnicode=true&characterEncoding=UTF-8&characterSetResults=UTF-8&zeroDateTimeBehavior=CONVERT_TO_NULL&connectTimeout=30000 with user 'admin' with locking mode 'minimal'
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      : Stopping down connector
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.MySqlConnectorTask   : Stopping MySQL connector task
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.ChainedReader        : ChainedReader: Stopping the snapshot reader
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.SnapshotReader       : Discarding 0 unsent record(s) due to the connector shutting down
2020-06-25 17:08:36.233  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.SnapshotReader       : Discarding 0 unsent record(s) due to the connector shutting down
2020-06-25 17:08:36.234  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       : Snapshot is using user 'admin' with these MySQL grants:
2020-06-25 17:08:36.234  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, RELOAD, SHUTDOWN, PROCESS, FILE, REFERENCES, INDEX, ALTER, SHOW DATABASES, SUPER, CREATE TEMPORARY TABLES, LOCK TABLES, EXECUTE, REPLICATION SLAVE, REPLICATION CLIENT, CREATE VIEW, SHOW VIEW, CREATE ROUTINE, ALTER ROUTINE, CREATE USER, EVENT, TRIGGER, CREATE TABLESPACE, CREATE ROLE, DROP ROLE ON *.* TO `admin`@`localhost` WITH GRANT OPTION
2020-06-25 17:08:36.234  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     GRANT APPLICATION_PASSWORD_ADMIN,AUDIT_ADMIN,BACKUP_ADMIN,BINLOG_ADMIN,BINLOG_ENCRYPTION_ADMIN,CLONE_ADMIN,CONNECTION_ADMIN,ENCRYPTION_KEY_ADMIN,GROUP_REPLICATION_ADMIN,INNODB_REDO_LOG_ARCHIVE,PERSIST_RO_VARIABLES_ADMIN,REPLICATION_APPLIER,REPLICATION_SLAVE_ADMIN,RESOURCE_GROUP_ADMIN,RESOURCE_GROUP_USER,ROLE_ADMIN,SERVICE_CONNECTION_ADMIN,SESSION_VARIABLES_ADMIN,SET_USER_ID,SHOW_ROUTINE,SYSTEM_USER,SYSTEM_VARIABLES_ADMIN,TABLE_ENCRYPTION_ADMIN,XA_RECOVER_ADMIN ON *.* TO `admin`@`localhost` WITH GRANT OPTION
2020-06-25 17:08:36.234  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     GRANT ALL PRIVILEGES ON `test_dev_core`.* TO `admin`@`localhost`
2020-06-25 17:08:36.234  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     GRANT SELECT ON `test_dev_core`.`servc_prvdr` TO `admin`@`localhost`
2020-06-25 17:08:36.234  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       : MySQL server variables related to change data capture:
2020-06-25 17:08:36.238  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.MySqlConnectorTask   : Connector task finished all work and is now shutdown
2020-06-25 17:08:36.239  INFO 2625 --- [pool-2-thread-1] o.a.k.c.storage.FileOffsetBackingStore   : Stopped FileOffsetBackingStore
2020-06-25 17:08:36.243  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_cache_size                             = 32768                                        
2020-06-25 17:08:36.243  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_checksum                               = CRC32                                        
2020-06-25 17:08:36.243  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_direct_non_transactional_updates       = OFF                                          
2020-06-25 17:08:36.243  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_encryption                             = OFF                                          
2020-06-25 17:08:36.243  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_error_action                           = ABORT_SERVER                                 
2020-06-25 17:08:36.243  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_expire_logs_seconds                    = 2592000                                      
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_format                                 = ROW                                          
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_group_commit_sync_delay                = 0                                            
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_group_commit_sync_no_delay_count       = 0                                            
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_gtid_simple_recovery                   = ON                                           
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_max_flush_queue_time                   = 0                                            
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_order_commits                          = ON                                           
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_rotate_encryption_master_key_at_startup = OFF                                          
2020-06-25 17:08:36.244  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_row_event_max_size                     = 8192                                         
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_row_image                              = FULL                                         
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_row_metadata                           = MINIMAL                                      
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_row_value_options                      =                                              
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_rows_query_log_events                  = OFF                                          
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_stmt_cache_size                        = 32768                                        
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_transaction_compression                = OFF                                          
2020-06-25 17:08:36.245  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_transaction_compression_level_zstd     = 3                                            
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_transaction_dependency_history_size    = 25000                                        
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     binlog_transaction_dependency_tracking        = COMMIT_ORDER                                 
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_client                          = utf8mb4                                      
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_connection                      = utf8mb4                                      
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_database                        = utf8mb4                                      
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_filesystem                      = binary                                       
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_results                         = utf8mb4                                      
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_server                          = utf8mb4                                      
2020-06-25 17:08:36.246  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_set_system                          = utf8                                         
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     character_sets_dir                            = /usr/share/mysql-8.0/charsets/               
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     collation_connection                          = utf8mb4_0900_ai_ci                           
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     collation_database                            = utf8mb4_0900_ai_ci                           
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     collation_server                              = utf8mb4_0900_ai_ci                           
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     default_collation_for_utf8mb4                 = utf8mb4_0900_ai_ci                           
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     enforce_gtid_consistency                      = OFF                                          
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     gtid_executed                                 =                                              
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     gtid_executed_compression_period              = 1000                                         
2020-06-25 17:08:36.247  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     gtid_mode                                     = OFF                                          
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     gtid_next                                     = AUTOMATIC                                    
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     gtid_owned                                    =                                              
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     gtid_purged                                   =                                              
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     immediate_server_version                      = 999999                                       
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     innodb_api_enable_binlog                      = OFF                                          
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     innodb_version                                = 8.0.20                                       
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     log_statements_unsafe_for_binlog              = ON                                           
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     max_binlog_cache_size                         = 18446744073709547520                         
2020-06-25 17:08:36.248  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     max_binlog_size                               = 1073741824                                   
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     max_binlog_stmt_cache_size                    = 18446744073709547520                         
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     original_server_version                       = 999999                                       
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     protocol_version                              = 10                                           
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     session_track_gtids                           = OFF                                          
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     slave_type_conversions                        =                                              
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     sync_binlog                                   = 1                                            
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     system_time_zone                              = -03                                          
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     time_zone                                     = SYSTEM                                       
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     tls_version                                   = TLSv1,TLSv1.1,TLSv1.2,TLSv1.3                
2020-06-25 17:08:36.249  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     version                                       = 8.0.20                                       
2020-06-25 17:08:36.250  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     version_comment                               = MySQL Community Server - GPL                 
2020-06-25 17:08:36.250  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     version_compile_machine                       = x86_64                                       
2020-06-25 17:08:36.250  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     version_compile_os                            = Linux                                        
2020-06-25 17:08:36.250  INFO 2625 --- [lacore-snapshot] i.d.connector.mysql.SnapshotReader       :     version_compile_zlib                          = 1.2.11                                       
2020-06-25 17:08:36.332  INFO 2625 --- [           main] o.s.s.concurrent.ThreadPoolTaskExecutor  : Initializing ExecutorService 'applicationTaskExecutor'
2020-06-25 17:08:36.486  INFO 2625 --- [           main] o.s.b.a.e.web.EndpointLinksResolver      : Exposing 2 endpoint(s) beneath base path '/actuator'
2020-06-25 17:08:36.527  INFO 2625 --- [           main] o.s.b.w.embedded.tomcat.TomcatWebServer  : Tomcat started on port(s): 8080 (http) with context path ''
2020-06-25 17:08:36.529  INFO 2625 --- [           main] com.test.cdc.CDCRelayApplication  : Started CDCRelayApplication in 2.236 seconds (JVM running for 2.484)
有人知道为什么会这样吗


谢谢大家

白名单表的格式为
。您只有表名部分。

白名单表的格式为
。您只有表名部分。

查看您的配置,提交偏移量时,
偏移量.dat
将在60秒后创建。出于测试目的,您可以减少偏移量.flush.interval.ms

让我更感兴趣的是

2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      : Stopping down connector
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.MySqlConnectorTask   : Stopping MySQL connector task
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.ChainedReader        : ChainedReader: Stopping the snapshot reader

您可以在
try
块中创建引擎,以便在块离开后立即停止(关闭)。代码应该保留在该块中。

查看配置,提交偏移量时,
偏移量.dat
将在60秒后创建。出于测试目的,您可以减少偏移量.flush.interval.ms

让我更感兴趣的是

2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      : Stopping down connector
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.MySqlConnectorTask   : Stopping MySQL connector task
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.ChainedReader        : ChainedReader: Stopping the snapshot reader

您可以在
try
块中创建引擎,以便在块离开后立即停止(关闭)。你的代码应该留在那个街区。

你好,朋友,你好吗?首先,谢谢你的回答。我做了你在我的coreDatabaseWhitelistTables中指出的更改,但我仍然没有得到CDC的响应。你有没有其他想法,为什么我没有收到CDC的更新?你好,Bruno CesarHi,你能试着停止Debezium引擎,移除
/tmp/offset.dat
/tmp/dbhistory.dat
并重新开始吗?你好,Jiri?再次感谢你的帮助!我删除了文件dbhistory.dat,但注意到offsets.dat没有创建。我将用我的启动应用程序日志编辑我的帖子,这样你就可以查看是否有错误或遗漏。你好,朋友,你好吗?首先,谢谢你的回答。我做了你在我的coreDatabaseWhitelistTables中指出的更改,但我仍然没有得到CDC的响应。你有没有其他想法,为什么我没有收到CDC的更新?你好,Bruno CesarHi,你能试着停止Debezium引擎,移除
/tmp/offset.dat
/tmp/dbhistory.dat
并重新开始吗?你好,Jiri?再次感谢你的帮助!我删除了文件dbhistory.dat,但注意到offsets.dat没有创建。我将用我的启动应用程序日志编辑我的帖子,这样你就可以查看是否有错误或遗漏。嗨,jiri!你好吗?很抱歉耽误了你的回复。从对我有用的Try块中删除Debezium引擎对象实例!谢谢你所有的支持。你好,jiri!你好吗?很抱歉耽误了你的回复。从对我有用的Try块中删除Debezium引擎对象实例!谢谢大家的支持。
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.common.BaseSourceTask      : Stopping down connector
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.MySqlConnectorTask   : Stopping MySQL connector task
2020-06-25 17:08:36.232  INFO 2625 --- [pool-2-thread-1] i.d.connector.mysql.ChainedReader        : ChainedReader: Stopping the snapshot reader