public class MySqlConnectorConfig extends RelationalDatabaseConnectorConfig
Modifier and Type | Class and Description |
---|---|
static class |
MySqlConnectorConfig.BigIntUnsignedHandlingMode
The set of predefined BigIntUnsignedHandlingMode options or aliases.
|
static class |
MySqlConnectorConfig.GtidNewChannelPosition
The set of predefined Gtid New Channel Position options.
|
static class |
MySqlConnectorConfig.SecureConnectionMode
The set of predefined SecureConnectionMode options or aliases.
|
static class |
MySqlConnectorConfig.SnapshotLockingMode
The set of predefined Snapshot Locking Mode options.
|
static class |
MySqlConnectorConfig.SnapshotMode
The set of predefined SnapshotMode options or aliases.
|
static class |
MySqlConnectorConfig.SnapshotNewTables |
RelationalDatabaseConnectorConfig.DecimalHandlingMode
CommonConnectorConfig.BinaryHandlingMode, CommonConnectorConfig.EventProcessingFailureHandlingMode, CommonConnectorConfig.Version
Modifier and Type | Field and Description |
---|---|
static Field.Set |
ALL_FIELDS
The set of
Field s defined as part of this configuration. |
static Field |
BIGINT_UNSIGNED_HANDLING_MODE |
static Field |
BUFFER_SIZE_FOR_BINLOG_READER |
static Field |
CONNECTION_TIMEOUT_MS |
private Duration |
connectionTimeout |
static Field |
DATABASE_BLACKLIST
A comma-separated list of regular expressions that match database names to be excluded from monitoring.
|
private static String |
DATABASE_BLACKLIST_NAME |
static Field |
DATABASE_HISTORY
The database history class is hidden in the
configDef() since that is designed to work with a user interface,
and in these situations using Kafka is the only way to go. |
static Field |
DATABASE_WHITELIST
A comma-separated list of regular expressions that match database names to be monitored.
|
private static String |
DATABASE_WHITELIST_NAME |
private static int |
DEFAULT_BINLOG_BUFFER_SIZE
Default size of the binlog buffer used for examining transactions and
deciding whether to propagate them or not.
|
protected static int |
DEFAULT_SNAPSHOT_FETCH_SIZE
Minimum value used for fetch size hint. |
static Field |
ENABLE_TIME_ADJUSTER |
static Field |
EVENT_DESERIALIZATION_FAILURE_HANDLING_MODE |
protected static Field.Set |
EXPOSED_FIELDS
The set of
Field s that are included in the configuration definition . |
private MySqlConnectorConfig.GtidNewChannelPosition |
gitIdNewChannelPosition |
static Field |
GTID_NEW_CHANNEL_POSITION
If set to 'latest', connector when encountering new GTID channel after job restart will start reading it from the
latest executed position (default).
|
static Field |
GTID_SOURCE_EXCLUDES
A comma-separated list of regular expressions that match source UUIDs in the GTID set used to find the binlog
position in the MySQL server.
|
static Field |
GTID_SOURCE_FILTER_DML_EVENTS
If set to true, we will only produce DML events into Kafka for transactions that were written on MySQL servers
with UUIDs matching the filters defined by the
GTID_SOURCE_INCLUDES or GTID_SOURCE_EXCLUDES
configuration options, if they are specified. |
static Field |
GTID_SOURCE_INCLUDES
A comma-separated list of regular expressions that match source UUIDs in the GTID set used to find the binlog
position in the MySQL server.
|
static Field |
HOSTNAME |
static Field |
INCLUDE_SQL_QUERY |
static Field |
INCONSISTENT_SCHEMA_HANDLING_MODE |
static Field |
JDBC_DRIVER |
static Field |
KEEP_ALIVE |
static Field |
KEEP_ALIVE_INTERVAL_MS |
private static org.slf4j.Logger |
LOGGER |
static Field |
ON_CONNECT_STATEMENTS |
static Field |
PASSWORD |
static Field |
PORT |
static Field |
ROW_COUNT_FOR_STREAMING_RESULT_SETS |
static Field |
SERVER_ID |
static Field |
SERVER_ID_OFFSET |
static Field |
SERVER_NAME |
static Field |
SNAPSHOT_LOCKING_MODE |
static Field |
SNAPSHOT_MODE |
static Field |
SNAPSHOT_NEW_TABLES |
private MySqlConnectorConfig.SnapshotLockingMode |
snapshotLockingMode |
private MySqlConnectorConfig.SnapshotNewTables |
snapshotNewTables |
static Field |
SSL_KEYSTORE |
static Field |
SSL_KEYSTORE_PASSWORD |
static Field |
SSL_MODE |
static Field |
SSL_TRUSTSTORE |
static Field |
SSL_TRUSTSTORE_PASSWORD |
static Field |
TABLES_IGNORE_BUILTIN |
private TemporalPrecisionMode |
temporalPrecisionMode |
static Field |
TIME_PRECISION_MODE |
static Field |
USER |
COLUMN_BLACKLIST, COLUMN_WHITELIST, CONFIG_DEFINITION, DECIMAL_HANDLING_MODE, DEFAULT_SNAPSHOT_LOCK_TIMEOUT_MILLIS, INCLUDE_SCHEMA_CHANGES, MASK_COLUMN, MASK_COLUMN_WITH_HASH, MSG_KEY_COLUMNS, SCHEMA_BLACKLIST, SCHEMA_WHITELIST, SNAPSHOT_LOCK_TIMEOUT_MS, SNAPSHOT_SELECT_STATEMENT_OVERRIDES_BY_TABLE, TABLE_BLACKLIST, TABLE_BLACKLIST_NAME, TABLE_IGNORE_BUILTIN, TABLE_WHITELIST, TABLE_WHITELIST_NAME, TRUNCATE_COLUMN
BINARY_HANDLING_MODE, CUSTOM_CONVERTERS, DATABASE_CONFIG_PREFIX, DEFAULT_MAX_BATCH_SIZE, DEFAULT_MAX_QUEUE_SIZE, DEFAULT_POLL_INTERVAL_MILLIS, EVENT_PROCESSING_FAILURE_HANDLING_MODE, MAX_BATCH_SIZE, MAX_QUEUE_SIZE, POLL_INTERVAL_MS, PROVIDE_TRANSACTION_METADATA, SANITIZE_FIELD_NAMES, SKIPPED_OPERATIONS, SNAPSHOT_DELAY_MS, SNAPSHOT_FETCH_SIZE, SOURCE_STRUCT_MAKER_VERSION, TOMBSTONES_ON_DELETE
Constructor and Description |
---|
MySqlConnectorConfig(Configuration config) |
getDecimalMode, getKeyMapper, getSnapshotSelectOverridesByTable, getTableFilters, getTableIdMapper, isSchemaChangesHistoryEnabled, snapshotLockTimeout
binaryHandlingMode, customConverterRegistry, getConfig, getEventProcessingFailureHandlingMode, getHeartbeatTopicsPrefix, getLogicalName, getMaxBatchSize, getMaxQueueSize, getPollInterval, getSanitizeFieldNames, getSkippedOps, getSnapshotDelay, getSnapshotFetchSize, getSourceInfoStructMaker, isEmitTombstoneOnDelete, shouldProvideTransactionMetadata, validateServerNameIsDifferentFromHistoryTopicName
private static final org.slf4j.Logger LOGGER
protected static final int DEFAULT_SNAPSHOT_FETCH_SIZE
Minimum value
used for fetch size hint.
See DBZ-94 for details.private static final String DATABASE_WHITELIST_NAME
private static final String DATABASE_BLACKLIST_NAME
private static final int DEFAULT_BINLOG_BUFFER_SIZE
public static final Field HOSTNAME
public static final Field PORT
public static final Field USER
public static final Field PASSWORD
public static final Field ON_CONNECT_STATEMENTS
public static final Field SERVER_NAME
public static final Field SERVER_ID
public static final Field SERVER_ID_OFFSET
public static final Field SSL_MODE
public static final Field SSL_KEYSTORE
public static final Field SSL_KEYSTORE_PASSWORD
public static final Field SSL_TRUSTSTORE
public static final Field SSL_TRUSTSTORE_PASSWORD
public static final Field TABLES_IGNORE_BUILTIN
public static final Field JDBC_DRIVER
public static final Field DATABASE_WHITELIST
DATABASE_BLACKLIST
.public static final Field DATABASE_BLACKLIST
DATABASE_WHITELIST
.public static final Field GTID_SOURCE_INCLUDES
GTID_SOURCE_EXCLUDES
.public static final Field GTID_SOURCE_EXCLUDES
GTID_SOURCE_INCLUDES
.public static final Field GTID_SOURCE_FILTER_DML_EVENTS
GTID_SOURCE_INCLUDES
or GTID_SOURCE_EXCLUDES
configuration options, if they are specified.
Defaults to true.
When true, either GTID_SOURCE_INCLUDES
or GTID_SOURCE_EXCLUDES
must be set.public static final Field GTID_NEW_CHANNEL_POSITION
public static final Field CONNECTION_TIMEOUT_MS
public static final Field KEEP_ALIVE
public static final Field KEEP_ALIVE_INTERVAL_MS
public static final Field ROW_COUNT_FOR_STREAMING_RESULT_SETS
public static final Field BUFFER_SIZE_FOR_BINLOG_READER
public static final Field DATABASE_HISTORY
configDef()
since that is designed to work with a user interface,
and in these situations using Kafka is the only way to go.public static final Field INCLUDE_SQL_QUERY
public static final Field SNAPSHOT_MODE
public static final Field SNAPSHOT_LOCKING_MODE
public static final Field SNAPSHOT_NEW_TABLES
public static final Field TIME_PRECISION_MODE
public static final Field BIGINT_UNSIGNED_HANDLING_MODE
public static final Field EVENT_DESERIALIZATION_FAILURE_HANDLING_MODE
public static final Field INCONSISTENT_SCHEMA_HANDLING_MODE
public static final Field ENABLE_TIME_ADJUSTER
public static Field.Set ALL_FIELDS
Field
s defined as part of this configuration.protected static Field.Set EXPOSED_FIELDS
Field
s that are included in the configuration definition
. This includes
all fields defined in this class (though some are always invisible since they are not to be exposed to the user interface)
plus several that are specific to the KafkaDatabaseHistory
class, since history is always stored in Kafka
when run via the user interface.private final MySqlConnectorConfig.SnapshotLockingMode snapshotLockingMode
private final MySqlConnectorConfig.GtidNewChannelPosition gitIdNewChannelPosition
private final MySqlConnectorConfig.SnapshotNewTables snapshotNewTables
private final TemporalPrecisionMode temporalPrecisionMode
private final Duration connectionTimeout
public MySqlConnectorConfig(Configuration config)
public MySqlConnectorConfig.SnapshotLockingMode getSnapshotLockingMode()
public MySqlConnectorConfig.GtidNewChannelPosition gtidNewChannelPosition()
public MySqlConnectorConfig.SnapshotNewTables getSnapshotNewTables()
protected static org.apache.kafka.common.config.ConfigDef configDef()
private static int validateGtidNewChannelPositionNotSet(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateEventDeserializationFailureHandlingModeNotSet(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateInconsistentSchemaHandlingModeNotIgnore(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateDatabaseBlacklist(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateTableBlacklist(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateGtidSetExcludes(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateSnapshotLockingMode(Configuration config, Field field, Field.ValidationOutput problems)
private static int validateTimePrecisionMode(Configuration config, Field field, Field.ValidationOutput problems)
adaptive
is specified, this option has the potential to cause overflow which is why the
option was deprecated and no longer supported for this connector.private static int randomServerId()
protected SourceInfoStructMaker<? extends AbstractSourceInfo> getSourceInfoStructMaker(CommonConnectorConfig.Version version)
getSourceInfoStructMaker
in class CommonConnectorConfig
public String getContextName()
getContextName
in class CommonConnectorConfig
public String getConnectorName()
getConnectorName
in class CommonConnectorConfig
public TemporalPrecisionMode getTemporalPrecisionMode()
getTemporalPrecisionMode
in class RelationalDatabaseConnectorConfig
public Duration getConnectionTimeout()
Copyright © 2020 JBoss by Red Hat. All rights reserved.