cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject cassandra-dtest git commit: Only expect value skipping during reads from 3.4+
Date Mon, 30 Jul 2018 08:42:19 GMT
Repository: cassandra-dtest
Updated Branches:
  refs/heads/master bed040c54 -> daa37bfb5


Only expect value skipping during reads from 3.4+

Patch by Sam Tunnicliffe; reviewed by Jason Brown for CASSANDRA-14603


Project: http://git-wip-us.apache.org/repos/asf/cassandra-dtest/repo
Commit: http://git-wip-us.apache.org/repos/asf/cassandra-dtest/commit/daa37bfb
Tree: http://git-wip-us.apache.org/repos/asf/cassandra-dtest/tree/daa37bfb
Diff: http://git-wip-us.apache.org/repos/asf/cassandra-dtest/diff/daa37bfb

Branch: refs/heads/master
Commit: daa37bfb56fbcf627abc7179fd5924af08bac429
Parents: bed040c
Author: Sam Tunnicliffe <sam@beobal.com>
Authored: Fri Jul 27 14:17:49 2018 +0100
Committer: Sam Tunnicliffe <sam@beobal.com>
Committed: Mon Jul 30 09:21:28 2018 +0100

----------------------------------------------------------------------
 read_repair_test.py | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cassandra-dtest/blob/daa37bfb/read_repair_test.py
----------------------------------------------------------------------
diff --git a/read_repair_test.py b/read_repair_test.py
index b6bfc37..175e19e 100644
--- a/read_repair_test.py
+++ b/read_repair_test.py
@@ -58,7 +58,8 @@ class TestReadRepair(Tester):
 
         # The read repair should have repaired the replicas, at least partially (see CASSANDRA-10655)
         # verify by querying each replica in turn.
-        self.check_data_on_each_replica(expect_fully_repaired=False, initial_replica=initial_replica)
+        value_skipping_disabled = True if self.cluster.version() < '3.4' else False
+        self.check_data_on_each_replica(expect_fully_repaired=value_skipping_disabled, initial_replica=initial_replica)
 
         # Now query again at CL.ALL but this time selecting all columns, which should ensure
that 'b' also gets repaired
         query = "SELECT * FROM alter_rf_test.t1 WHERE k=1"
@@ -92,14 +93,16 @@ class TestReadRepair(Tester):
                                                     consistency_level=ConsistencyLevel.ONE))
 
         # Query each replica individually to ensure that read repair was triggered. We should
expect that only
-        # the initial replica has data for both the 'a' and 'b' columns. The read repair
should only have affected
-        # the selected column, so the other two replicas should only have that data.
+        # the initial replica has data for both the 'a' and 'b' columns. If the cluster is
on > 3.4, the read repair
+        # should only have affected the selected column (CASSANDRA-10655), so the other two
replicas should only have
+        # that data.
         # Note: we need to temporarily set read_repair_chance to 0 while we perform this
check.
         logger.debug("Setting table read repair chance to 0 while we verify each replica's
data")
         session.execute("""ALTER TABLE alter_rf_test.t1 WITH read_repair_chance = 0;""")
         # The read repair is run in the background, so we spin while checking that the repair
has completed
+        value_skipping_disabled = True if self.cluster.version() < '3.4' else False
         retry_till_success(self.check_data_on_each_replica,
-                           expect_fully_repaired=False,
+                           expect_fully_repaired=value_skipping_disabled,
                            initial_replica=initial_replica,
                            timeout=30,
                            bypassed_exception=NotRepairedException)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org
For additional commands, e-mail: commits-help@cassandra.apache.org


Mime
View raw message