smiklosovic commented on code in PR #2047:
URL: https://github.com/apache/cassandra/pull/2047#discussion_r1051661022


##########
test/distributed/org/apache/cassandra/distributed/upgrade/CompactionHistorySystemTableUpgradeTest.java:
##########
@@ -39,26 +39,22 @@ public void compactionHistorySystemTableTest() throws 
Throwable
             .nodes(2)
             .nodesToUpgrade(2)
             .upgradesToCurrentFrom(v40).setup((cluster) -> {
-              //create table    
+              //create table
             cluster.schemaChange("CREATE TABLE " + KEYSPACE + ".tb (" +
                 "pk text PRIMARY KEY," +
                 "c1 text," +
                 "c2 int," +
                 "c3 int)");
-          
              // disable auto compaction
             cluster.stream().forEach(node -> 
node.nodetool("disableautocompaction"));
-          
             // generate sstables
-            for (int i = 0; i != 10; ++ i) 
+            for (int i = 0; i != 10; ++ i)
             {
                 cluster.coordinator(1).execute("INSERT INTO " + KEYSPACE + 
".tb (pk, c1, c2, c3) VALUES ('pk" + i + "', 'c1" + i + "', " + i + ',' + i + 
')'  , ConsistencyLevel.ALL);
                 cluster.stream().forEach(node -> node.flush(KEYSPACE));
             }
-          
             // force compact
             cluster.stream().forEach(node -> node.forceCompact(KEYSPACE, 
"tb"));
-          
         }).runAfterNodeUpgrade((cluster, node) -> {
           String query = "SELECT compaction_type FROM " + KEYSPACE + ".tb 
where keyspace_name = '" + KEYSPACE + "' AND columnfamily_name = 'tb' ALLOW 
FILTERING";

Review Comment:
   @Maxwell-Guo I do not think this is right. You are selecting from keyspace 
`KEYSPACE` and table `tb`. Should not that be `system.compaction_history`? Have 
you tried to execute this test?



-- 
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]

Reply via email to