Package io.debezium.connector.mariadb
Class MariaDbSnapshotChangeEventSource
java.lang.Object
io.debezium.pipeline.source.AbstractSnapshotChangeEventSource<P,O>
io.debezium.relational.RelationalSnapshotChangeEventSource<P,O>
io.debezium.connector.binlog.BinlogSnapshotChangeEventSource<MariaDbPartition,MariaDbOffsetContext>
io.debezium.connector.mariadb.MariaDbSnapshotChangeEventSource
- All Implemented Interfaces:
io.debezium.pipeline.source.spi.ChangeEventSource,io.debezium.pipeline.source.spi.SnapshotChangeEventSource<MariaDbPartition,,MariaDbOffsetContext> AutoCloseable
public class MariaDbSnapshotChangeEventSource
extends BinlogSnapshotChangeEventSource<MariaDbPartition,MariaDbOffsetContext>
A
SnapshotChangeEventSource implementation for MariaDB.- Author:
- Chris Cranford
-
Nested Class Summary
Nested classes/interfaces inherited from class io.debezium.relational.RelationalSnapshotChangeEventSource
io.debezium.relational.RelationalSnapshotChangeEventSource.RelationalSnapshotContext<P extends io.debezium.pipeline.spi.Partition,O extends io.debezium.pipeline.spi.OffsetContext> Nested classes/interfaces inherited from class io.debezium.pipeline.source.AbstractSnapshotChangeEventSource
io.debezium.pipeline.source.AbstractSnapshotChangeEventSource.SnapshotContext<P extends io.debezium.pipeline.spi.Partition,O extends io.debezium.pipeline.spi.OffsetContext> Nested classes/interfaces inherited from interface io.debezium.pipeline.source.spi.ChangeEventSource
io.debezium.pipeline.source.spi.ChangeEventSource.ChangeEventSourceContext -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final MariaDbConnectorConfigprivate static final org.slf4j.LoggerFields inherited from class io.debezium.relational.RelationalSnapshotChangeEventSource
clock, connectionPool, dispatcher, MATCH_ALL_PATTERN, SELECT_ALL_PATTERN, snapshotterServiceFields inherited from class io.debezium.pipeline.source.AbstractSnapshotChangeEventSource
LOG_INTERVAL, notificationService -
Constructor Summary
ConstructorsConstructorDescriptionMariaDbSnapshotChangeEventSource(MariaDbConnectorConfig connectorConfig, io.debezium.jdbc.MainConnectionProvidingConnectionFactory<BinlogConnectorConnection> connectionFactory, MariaDbDatabaseSchema schema, io.debezium.pipeline.EventDispatcher<MariaDbPartition, io.debezium.relational.TableId> dispatcher, io.debezium.util.Clock clock, MariaDbSnapshotChangeEventSourceMetrics metrics, io.debezium.function.BlockingConsumer<Function<org.apache.kafka.connect.source.SourceRecord, org.apache.kafka.connect.source.SourceRecord>> lastEventProcessor, Runnable preSnapshotAction, io.debezium.pipeline.notification.NotificationService<MariaDbPartition, MariaDbOffsetContext> notificationService, io.debezium.snapshot.SnapshotterService snapshotterService) -
Method Summary
Modifier and TypeMethodDescriptionprotected MariaDbOffsetContextcopyOffset(io.debezium.relational.RelationalSnapshotChangeEventSource.RelationalSnapshotContext<MariaDbPartition, MariaDbOffsetContext> snapshotContext) protected MariaDbOffsetContextgetInitialOffsetContext(BinlogConnectorConfig connectorConfig) protected voidsetOffsetContextBinlogPositionAndGtidDetailsForSnapshot(MariaDbOffsetContext offsetContext, BinlogConnectorConnection connection, io.debezium.snapshot.SnapshotterService snapshotterService) Methods inherited from class io.debezium.connector.binlog.BinlogSnapshotChangeEventSource
createSchemaChangeEventsForTables, determineSnapshotOffset, getAllTableIds, getCreateTableEvent, getSnapshotConnectionFirstSelect, getSnapshotSelect, lockTablesForSchemaSnapshot, postSnapshot, prepare, preSnapshot, readTableStatement, readTableStructure, releaseDataSnapshotLocks, releaseSchemaSnapshotLocks, rowCountForTableMethods inherited from class io.debezium.relational.RelationalSnapshotChangeEventSource
additionalColumnFilter, connectionCreated, connectionPoolConnectionCreated, createDataEventsForTableCallable, createSnapshotConnection, doCreateDataEventsForTable, doExecute, enhanceOverriddenSelect, getBlockingSnapshottingTask, getChangeRecordEmitter, getClock, getPreparedColumnNames, getSignalDataCollectionPattern, getSnapshotSelectOverridesByTable, getSnapshotSourceTimestamp, getSnapshottingTask, getTablesForSchemaChange, lastSnapshotRecord, resultSetForDataEvents, tryStartingSnapshotMethods inherited from class io.debezium.pipeline.source.AbstractSnapshotChangeEventSource
aborted, close, completed, delaySnapshotIfNeeded, determineDataCollectionsToBeSnapshotted, execute, getDataCollectionPattern, getOffsets
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
connectorConfig
-
-
Constructor Details
-
MariaDbSnapshotChangeEventSource
public MariaDbSnapshotChangeEventSource(MariaDbConnectorConfig connectorConfig, io.debezium.jdbc.MainConnectionProvidingConnectionFactory<BinlogConnectorConnection> connectionFactory, MariaDbDatabaseSchema schema, io.debezium.pipeline.EventDispatcher<MariaDbPartition, io.debezium.relational.TableId> dispatcher, io.debezium.util.Clock clock, MariaDbSnapshotChangeEventSourceMetrics metrics, io.debezium.function.BlockingConsumer<Function<org.apache.kafka.connect.source.SourceRecord, org.apache.kafka.connect.source.SourceRecord>> lastEventProcessor, Runnable preSnapshotAction, io.debezium.pipeline.notification.NotificationService<MariaDbPartition, MariaDbOffsetContext> notificationService, io.debezium.snapshot.SnapshotterService snapshotterService)
-
-
Method Details
-
getInitialOffsetContext
- Specified by:
getInitialOffsetContextin classBinlogSnapshotChangeEventSource<MariaDbPartition,MariaDbOffsetContext>
-
setOffsetContextBinlogPositionAndGtidDetailsForSnapshot
protected void setOffsetContextBinlogPositionAndGtidDetailsForSnapshot(MariaDbOffsetContext offsetContext, BinlogConnectorConnection connection, io.debezium.snapshot.SnapshotterService snapshotterService) throws Exception - Specified by:
setOffsetContextBinlogPositionAndGtidDetailsForSnapshotin classBinlogSnapshotChangeEventSource<MariaDbPartition,MariaDbOffsetContext> - Throws:
Exception
-
copyOffset
protected MariaDbOffsetContext copyOffset(io.debezium.relational.RelationalSnapshotChangeEventSource.RelationalSnapshotContext<MariaDbPartition, MariaDbOffsetContext> snapshotContext) - Specified by:
copyOffsetin classio.debezium.relational.RelationalSnapshotChangeEventSource<MariaDbPartition,MariaDbOffsetContext>
-