yifan-c commented on code in PR #92:
URL:
https://github.com/apache/cassandra-analytics/pull/92#discussion_r1844294840
##########
cassandra-analytics-integration-tests/src/test/java/org/apache/cassandra/analytics/correctness/BulkWriteCorruptionTest.java:
##########
@@ -53,22 +56,55 @@
import static org.apache.cassandra.testing.TestUtils.ROW_COUNT;
import static org.apache.cassandra.testing.TestUtils.TEST_KEYSPACE;
import static org.assertj.core.api.Assertions.assertThat;
-import static org.assertj.core.api.Assertions.fail;
-public class BulkWriteDiskCorruptionTest extends
SharedClusterSparkIntegrationTestBase
+public class BulkWriteCorruptionTest extends
SharedClusterSparkIntegrationTestBase
{
- private static final QualifiedName QUALIFIED_NAME = new
QualifiedName(TEST_KEYSPACE, "test_write_disk_corruption");
+ enum CorruptionMode
+ {
+ DISK,
+ WIRE
+ }
+
+ private static final QualifiedName QUALIFIED_NAME = new
QualifiedName(TEST_KEYSPACE, "test_write_corruption");
static
{
- // Intercepts SortedSSTableWriter#validateSSTables to corrupt file on
purpose.
// Install the class rebase the earliest, before JVM loads the class
- BBHelperInterceptSortedSSTableWriterValidateSSTables.install();
+ BBHelperFileCorrupter.install();
Review Comment:
Made the change and I realized why having the switch.
Each test case only expect corruption at specific locations. Without the
switch, `testDataTransferCorruption` has the files corrupted on disk and fail.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]