Class MongoConnectorIT
- java.lang.Object
-
- io.debezium.testing.openshift.ConnectorTestBase
-
- io.debezium.testing.openshift.mongodb.MongoConnectorIT
-
@TestMethodOrder(org.junit.jupiter.api.MethodOrderer.OrderAnnotation.class) @Tag("acceptance") @Tag("mongo") public class MongoConnectorIT extends ConnectorTestBase- Author:
- Jakub Cechacek
-
-
Field Summary
Fields Modifier and Type Field Description static StringCONNECTOR_NAMEprivate static io.debezium.testing.openshift.tools.kafka.ConnectorConfigBuilderconnectorConfigprivate static StringconnectorNamestatic StringDB_DEPLOYMENT_PATHstatic StringDB_SERVICE_PATHstatic StringDB_SERVICE_PATH_LBprivate static io.debezium.testing.openshift.tools.databases.mongodb.MongoDatabaseControllerdbControllerprivate static StringdbServerName-
Fields inherited from class io.debezium.testing.openshift.ConnectorTestBase
assertions, connectorFactories, httpClient, KAFKA, KAFKA_CONNECT_S2I, KAFKA_CONNECT_S2I_LOGGING, KAFKA_CONSUMER_PROPS, kafkaConnectController, kafkaController, ocp, operatorController, REGISTRY_DEPLOYMENT_PATH, REGISTRY_ID_TOPIC_PATH, REGISTRY_STORAGE_TOPIC_PATH, registryController, registryDeployer, testUtils
-
-
Constructor Summary
Constructors Constructor Description MongoConnectorIT()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description private voidinsertCustomer(String firstName, String lastName, String email)static voidsetupDatabase()voidshouldBeDown()voidshouldBeDownAfterCrash()voidshouldContainRecordsInCustomersTopic()voidshouldCreateKafkaTopics()voidshouldHaveRegisteredConnector()voidshouldResumeStreamingAfterCrash()voidshouldResumeStreamingAfterRedeployment()voidshouldStreamChanges()static voidtearDownDatabase()-
Methods inherited from class io.debezium.testing.openshift.ConnectorTestBase
setup, teardown
-
-
-
-
Field Detail
-
DB_DEPLOYMENT_PATH
public static final String DB_DEPLOYMENT_PATH
- See Also:
- Constant Field Values
-
DB_SERVICE_PATH_LB
public static final String DB_SERVICE_PATH_LB
- See Also:
- Constant Field Values
-
DB_SERVICE_PATH
public static final String DB_SERVICE_PATH
- See Also:
- Constant Field Values
-
CONNECTOR_NAME
public static final String CONNECTOR_NAME
- See Also:
- Constant Field Values
-
dbController
private static io.debezium.testing.openshift.tools.databases.mongodb.MongoDatabaseController dbController
-
connectorConfig
private static io.debezium.testing.openshift.tools.kafka.ConnectorConfigBuilder connectorConfig
-
connectorName
private static String connectorName
-
dbServerName
private static String dbServerName
-
-
Method Detail
-
setupDatabase
@BeforeAll public static void setupDatabase() throws IOException, InterruptedException- Throws:
IOExceptionInterruptedException
-
tearDownDatabase
@AfterAll public static void tearDownDatabase() throws IOException, InterruptedException- Throws:
IOExceptionInterruptedException
-
shouldHaveRegisteredConnector
@Test @Order(1) public void shouldHaveRegisteredConnector()
-
shouldCreateKafkaTopics
@Test @Order(2) public void shouldCreateKafkaTopics()
-
shouldContainRecordsInCustomersTopic
@Test @Order(3) public void shouldContainRecordsInCustomersTopic() throws IOException- Throws:
IOException
-
shouldStreamChanges
@Test @Order(4) public void shouldStreamChanges()
-
shouldBeDown
@Test @Order(5) public void shouldBeDown() throws IOException- Throws:
IOException
-
shouldResumeStreamingAfterRedeployment
@Test @Order(6) public void shouldResumeStreamingAfterRedeployment() throws IOException, InterruptedException- Throws:
IOExceptionInterruptedException
-
shouldBeDownAfterCrash
@Test @Order(7) public void shouldBeDownAfterCrash()
-
shouldResumeStreamingAfterCrash
@Test @Order(8) public void shouldResumeStreamingAfterCrash() throws InterruptedException- Throws:
InterruptedException
-
-