public class FieldRenamesIT extends AbstractMongoConnectorIT
AbstractConnectorTest.SourceRecordsTesting.Debug, Testing.Files, Testing.InterruptableFunction, Testing.Network, Testing.Print, Testing.Timer| Modifier and Type | Field and Description |
|---|---|
private static String |
COLLECTION_NAME |
private static String |
DATABASE_NAME |
private static String |
ID |
private static String |
PATCH |
private static String |
SERVER_NAME |
config, context, logInterceptorengine, logger, logTestName, NO_MONITORED_TABLES_WARNING, OFFSET_STORE_PATH, pollTimeoutInMs, skipTestRule| Constructor and Description |
|---|
FieldRenamesIT() |
afterEach, beforEach, connectionErrorHandler, deleteDocuments, dropAndInsertDocuments, insertDocuments, insertDocumentsInTx, loadTestDocuments, primary, storeDocuments, storeDocuments, updateDocumentassertBeginTransaction, assertConfigurationErrors, assertConfigurationErrors, assertConfigurationErrors, assertConnectorIsRunning, assertConnectorNotRunning, assertDelete, assertEndTransaction, assertEngineIsRunning, assertHasNoSourceQuery, assertInsert, assertKey, assertNoConfigurationErrors, assertNoRecordsToConsume, assertOffset, assertOffset, assertRecordTransactionMetadata, assertSchemaMatchesStruct, assertSchemaMatchesStruct, assertSourceQuery, assertTombstone, assertTombstone, assertUpdate, assertValueField, configValue, consumeAvailableRecords, consumeRecord, consumeRecords, consumeRecords, consumeRecords, consumeRecordsByTopic, consumeRecordsByTopic, consumeRecordsByTopic, debug, getMaximumEnqueuedRecordCount, getSnapshotMetricsObjectName, getStreamingMetricsObjectName, getStreamingMetricsObjectName, initializeConnectorTestFramework, loggingCompletion, print, readLastCommittedOffset, readLastCommittedOffsets, setConsumeTimeout, start, start, start, start, stopConnector, stopConnector, validate, waitForAvailableRecords, waitForSnapshotToBeCompleted, waitForStreamingRunning, waitForStreamingRunningclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdebug, once, once, print, print, printError, printError, printError, resetBeforeEachTest, time, timeprivate static final String DATABASE_NAME
private static final String COLLECTION_NAME
private static final String SERVER_NAME
private static final String PATCH
private static final String ID
public void shouldNotRenameMissingFieldsForReadEvent()
throws Exception
Exceptionpublic void shouldNotRenameNestedMissingFieldsForReadEvent()
throws Exception
Exceptionpublic void shouldNotRenameMissingFieldsForInsertEvent()
throws Exception
Exceptionpublic void shouldNotRenameNestedMissingFieldsForInsertEvent()
throws Exception
Exceptionpublic void shouldNotRenameNestedMissingFieldsForUpdateEventWithEmbeddedDocument()
throws Exception
Exceptionpublic void shouldNotRenameFieldsForEventOfOtherCollection()
throws Exception
Exceptionpublic void shouldRenameFieldsForReadEvent()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForReadEvent()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsToExistingNamesForReadEvent()
throws Exception
Exceptionpublic void shouldRenameFieldsForInsertEvent()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForInsertEvent()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsToExistingNamesForInsertEvent()
throws Exception
Exceptionpublic void shouldRenameFieldsForUpdateEvent()
throws Exception
Exceptionpublic void shouldNotRenameMissingFieldsForUpdateEvent()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForUpdateEventWithEmbeddedDocument()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsToExistingNamesForUpdateEventWithEmbeddedDocument()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsForUpdateEventWithArrayOfArrays()
throws Exception
Exceptionpublic void shouldRenameFieldsForSetTopLevelFieldUpdateEvent()
throws Exception
Exceptionpublic void shouldNotRenameFieldsToExistingNamesForSetTopLevelFieldUpdateEvent()
throws Exception
Exceptionpublic void shouldRenameFieldsForUnsetTopLevelFieldUpdateEvent()
throws Exception
Exceptionpublic void shouldNotRenameFieldsToExistingNamesForUnsetTopLevelFieldUpdateEvent()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForSetTopLevelFieldUpdateEventWithEmbeddedDocument()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForSetTopLevelFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsForSetTopLevelFieldUpdateEventWithArrayOfArrays()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForSetNestedFieldUpdateEventWithEmbeddedDocument()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForSetNestedFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsToExistingNamesForSetNestedFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsForSetNestedFieldUpdateEventWithArrayOfArrays()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForSetNestedFieldUpdateEventWithSeveralArrays()
throws Exception
Exceptionpublic void shouldRenameFieldsForSetNestedFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldRenameFieldsForSetToArrayFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForUnsetNestedFieldUpdateEventWithEmbeddedDocument()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForUnsetNestedFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsToExistingNamesForUnsetNestedFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldNotRenameNestedFieldsForUnsetNestedFieldUpdateEventWithArrayOfArrays()
throws Exception
Exceptionpublic void shouldRenameNestedFieldsForUnsetNestedFieldUpdateEventWithSeveralArrays()
throws Exception
Exceptionpublic void shouldRenameFieldsForUnsetNestedFieldUpdateEventWithArrayOfEmbeddedDocuments()
throws Exception
Exceptionpublic void shouldRenameFieldsForDeleteEvent()
throws Exception
Exceptionpublic void shouldRenameFieldsForDeleteTombstoneEvent()
throws Exception
Exceptionprivate static org.bson.Document getFilterFromId(org.bson.types.ObjectId id)
private static org.bson.Document getDocumentFromPatch(org.apache.kafka.connect.data.Struct value)
private static Configuration getConfiguration(String fieldRenames)
private static Configuration getConfiguration(String fieldRenames, String database, String collection)
private org.apache.kafka.connect.source.SourceRecord getReadRecord(String fieldRenames, org.bson.Document document) throws Exception
Exceptionprivate org.apache.kafka.connect.source.SourceRecord getReadRecord(String database, String collection, String fieldRenames, org.bson.Document document) throws Exception
Exceptionprivate org.apache.kafka.connect.source.SourceRecord getInsertRecord(String fieldRenames, org.bson.Document document) throws Exception
Exceptionprivate org.apache.kafka.connect.source.SourceRecord getInsertRecord(String database, String collection, String fieldRenames, org.bson.Document document) throws Exception
Exceptionprivate org.apache.kafka.connect.source.SourceRecord getUpdateRecord(String fieldRenames, org.bson.Document snapshot, org.bson.Document document) throws Exception
Exceptionprivate org.apache.kafka.connect.source.SourceRecord getUpdateRecord(String database, String collection, String fieldRenames, org.bson.Document snapshot, org.bson.Document document) throws Exception
Exceptionprivate void assertDocumentContainsFieldError(String fieldName)
private void assertShouldNotRenameDuringRead(String renamesList, org.bson.Document snapshot, String fieldName) throws Exception
Exceptionprivate void assertShouldNotRenameDuringInsert(String renamesList, org.bson.Document document, String fieldName) throws Exception
ExceptionCopyright © 2020 JBoss by Red Hat. All rights reserved.