Class EmbeddedCassandraConnectorTestBase

    • Constructor Detail

      • EmbeddedCassandraConnectorTestBase

        public EmbeddedCassandraConnectorTestBase()
    • Method Detail

      • tearDownClass

        public static void tearDownClass()
      • truncateTestKeyspaceTableData

        protected static void truncateTestKeyspaceTableData()
        Truncate data in all tables in TEST_KEYSPACE, but do not drop the tables
      • deleteTestKeyspaceTables

        protected static void deleteTestKeyspaceTables()
        Drop all tables in TEST_KEYSPACE
      • generateTaskContext

        protected static io.debezium.connector.cassandra.CassandraConnectorContext generateTaskContext()
                                                                                                throws Exception
        Generate a task context with default test configs
        Throws:
        Exception
      • generateTaskContext

        protected static io.debezium.connector.cassandra.CassandraConnectorContext generateTaskContext​(Map<String,​Object> configs)
                                                                                                throws Exception
        General a task context with default and custom test configs
        Throws:
        Exception
      • deleteTestOffsets

        protected static void deleteTestOffsets​(io.debezium.connector.cassandra.CassandraConnectorContext context)
                                         throws IOException
        Delete all files in offset backing store directory
        Throws:
        IOException
      • keyspaceTable

        protected static String keyspaceTable​(String tableName)
        Return the full name of the test table in the form of .
        • generateCommitLogFile

          protected static File generateCommitLogFile()
          Generate a commit log file with current timestamp in memory
        • populateFakeCommitLogsForDirectory

          protected static void populateFakeCommitLogsForDirectory​(int numOfFiles,
                                                                   File directory)
                                                            throws IOException
          Generate commit log files in directory
          Throws:
          IOException
        • clearCommitLogFromDirectory

          protected static void clearCommitLogFromDirectory​(File directory,
                                                            boolean recursive)
                                                     throws IOException
          Delete all commit log files in directory
          Throws:
          IOException
        • startEmbeddedCassandra

          private static void startEmbeddedCassandra()
                                              throws Exception
          Throws:
          Exception
        • stopEmbeddedCassandra

          private static void stopEmbeddedCassandra()
        • createTestKeyspace

          private static void createTestKeyspace()
        • destroyTestKeyspace

          private static void destroyTestKeyspace()