Reputation: 81
I have a Spring Boot Application with Debezium Api embbeded to catch changes no my MySQL Database.
I'm trying to make Debezium Engine Api (v1.1.2) catch any changes on my MySQL local database.
But, for some reason, Embedded Debezium its not able to catch when any change happen.
Does anyone have any tip to help me?
Here's my configuration code
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
}
}
}
And here is my pom.xml dependencies
<dependency>
<groupId>io.debezium</groupId>
<artifactId>debezium-api</artifactId>
<version>1.1.2.Final</version>
</dependency>
<dependency>
<groupId>io.debezium</groupId>
<artifactId>debezium-embedded</artifactId>
<version>1.1.2.Final</version>
</dependency>
<dependency>
<groupId>io.debezium</groupId>
<artifactId>debezium-connector-mysql</artifactId>
<version>1.1.2.Final</version>
</dependency>
And the grants for my user is
'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'
'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'
'GRANT ALL PRIVILEGES ON `dev_core`.* TO `admin`@`localhost`'
'GRANT SELECT ON `dev_core`.`servc_prvdr` TO `admin`@`localhost`'
Here is my Spring Boot start-up application logs
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)
Anyone have any idea on why this is happening?
Thanks everyone!
Upvotes: 0
Views: 2675
Reputation: 1976
Looking at your config the offsets.dat
will create after 60 seconnds when the offsets are committed. You can reduce the offset.flush.interval.ms
for test purposes.
What conecnerns me more is
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
You create the engine in try
block so it is stopped (closed) as soon as the block left. You code should stay in that block.
Upvotes: 1
Reputation: 1976
the whitelist table is in format <databasename>.<tablename>
. You have only table name part.
Upvotes: 1