Package io.debezium.connector.mysql
Class StreamingSourceIT
java.lang.Object
io.debezium.embedded.AbstractConnectorTest
io.debezium.connector.mysql.StreamingSourceIT
- All Implemented Interfaces:
Testing
- Author:
- Randall Hauch, Jiri Pechanec
-
Nested Class Summary
Nested classes/interfaces inherited from class io.debezium.embedded.AbstractConnectorTest
AbstractConnectorTest.SourceRecordsNested classes/interfaces inherited from interface io.debezium.util.Testing
Testing.Debug, Testing.Files, Testing.InterruptableFunction, Testing.Network, Testing.Print, Testing.Timer -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Configurationprivate final UniqueDatabaseprivate static final Pathprivate SchemaChangeHistoryprivate static final Stringorg.junit.rules.TestRuleprivate KeyValueStoreFields inherited from class io.debezium.embedded.AbstractConnectorTest
consumedLines, engine, logger, logTestName, OFFSET_STORE_PATH, pollTimeoutInMs, skipTestRule -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidprotected intconsumeAtLeast(int minNumber) protected intconsumeAtLeast(int minNumber, long timeout, TimeUnit unit) protected longfilterAtLeast(int minNumber, long timeout, TimeUnit unit) private longprivate longprivate voidprivate StringvoidvoidvoidvoidvoidvoidSetup a DATABASE_INCLUDE_LIST filter that filters all events.voidvoidvoidvoidprotected Configuration.Buildervoidprivate DurationtoDuration(String duration) Methods inherited from class io.debezium.embedded.AbstractConnectorTest
assertBeginTransaction, assertConfigurationErrors, assertConfigurationErrors, assertConfigurationErrors, assertConnectorIsRunning, assertConnectorNotRunning, assertDelete, assertEndTransaction, assertEngineIsRunning, assertHasNoSourceQuery, assertInsert, assertKey, assertNoConfigurationErrors, assertNoRecordsToConsume, assertOffset, assertOffset, assertOnlyTransactionRecordsToConsume, assertRecordTransactionMetadata, assertSchemaMatchesStruct, assertSchemaMatchesStruct, assertSourceQuery, assertTombstone, assertTombstone, assertUpdate, assertValueField, configValue, consumeAvailableRecords, consumeAvailableRecordsByTopic, consumeDmlRecordsByTopic, consumeDmlRecordsByTopic, consumeDmlRecordsByTopic, consumeRecord, consumeRecords, consumeRecords, consumeRecords, consumeRecordsButSkipUntil, consumeRecordsByTopic, consumeRecordsByTopic, consumeRecordsByTopic, consumeRecordsByTopicUntil, consumeRecordsUntil, debug, getConsumer, getMaximumEnqueuedRecordCount, getSnapshotMetricsObjectName, getSnapshotMetricsObjectName, getSnapshotMetricsObjectName, getStreamingMetricsObjectName, getStreamingMetricsObjectName, getStreamingMetricsObjectName, getStreamingMetricsObjectName, getStreamingNamespace, initializeConnectorTestFramework, isStreamingRunning, isStreamingRunning, isStreamingRunning, isStreamingRunning, isTransactionRecord, loggingCompletion, print, readLastCommittedOffset, readLastCommittedOffsets, setConsumeTimeout, skipAvroValidation, start, start, start, start, start, start, start, startAndConsumeTillEnd, startAndConsumeTillEnd, stopConnector, stopConnector, validate, waitForAvailableRecords, waitForConnectorShutdown, waitForNotInitialState, waitForSnapshotToBeCompleted, waitForSnapshotToBeCompleted, waitForSnapshotWithCustomMetricsToBeCompleted, waitForStreamingRunning, waitForStreamingRunning, waitForStreamingRunning, waitForStreamingWithCustomMetricsToStart, waitTimeForRecords, waitTimeForRecordsAfterNulls
-
Field Details
-
SCHEMA_HISTORY_PATH
-
DATABASE
-
SET_TLS_PROTOCOLS
- See Also:
-
config
-
store
-
schemaChanges
-
skipRule
public org.junit.rules.TestRule skipRule
-
-
Constructor Details
-
StreamingSourceIT
public StreamingSourceIT()
-
-
Method Details
-
beforeEach
public void beforeEach() -
afterEach
public void afterEach() -
consumeAtLeast
- Throws:
InterruptedException
-
consumeAtLeast
protected int consumeAtLeast(int minNumber, long timeout, TimeUnit unit) throws InterruptedException - Throws:
InterruptedException
-
filterAtLeast
protected long filterAtLeast(int minNumber, long timeout, TimeUnit unit) throws InterruptedException - Throws:
InterruptedException
-
getNumberOfEventsFiltered
private long getNumberOfEventsFiltered() -
getNumberOfSkippedEvents
private long getNumberOfSkippedEvents() -
simpleConfig
-
shouldCreateSnapshotOfSingleDatabase
- Throws:
Exception
-
shouldCreateSnapshotOfSingleDatabaseWithSchemaChanges
- Throws:
Exception
-
shouldFilterAllRecordsBasedOnDatabaseIncludeListFilter
@FixFor("DBZ-1206") public void shouldFilterAllRecordsBasedOnDatabaseIncludeListFilter() throws ExceptionSetup a DATABASE_INCLUDE_LIST filter that filters all events. Verify all events are properly filtered. Verify numberOfFilteredEvents metric is incremented correctly.- Throws:
Exception
-
shouldHandleTimestampTimezones
- Throws:
Exception
-
shouldHandleMySQLTimeCorrectly
- Throws:
Exception
-
shouldFailOnSchemaInconsistency
- Throws:
Exception
-
shouldWarnOnSchemaInconsistency
- Throws:
Exception
-
shouldIgnoreOnSchemaInconsistency
- Throws:
Exception
-
shouldFailOnUnknownTlsProtocol
-
shouldAcceptTls12
- Throws:
Exception
-
testHeartbeatActionQueryExecuted
- Throws:
Exception
-
inconsistentSchema
private void inconsistentSchema(CommonConnectorConfig.EventProcessingFailureHandlingMode mode) throws InterruptedException, SQLException - Throws:
InterruptedExceptionSQLException
-
toDuration
-
productsTableName
- Throws:
SQLException
-