You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pr@cassandra.apache.org by "maedhroz (via GitHub)" <gi...@apache.org> on 2026/04/23 23:19:58 UTC

[PR] Ensure SAI sends range tombstones to the coordinator for queries on static columns [cassandra]

maedhroz opened a new pull request, #4768:
URL: https://github.com/apache/cassandra/pull/4768

   patch by Caleb Rackliffe; reviewed by ? for CASSANDRA-21332


-- 
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: pr-unsubscribe@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


Re: [PR] CASSANDRA-21332 Ensure SAI sends range tombstones to the coordinator for queries on static columns [cassandra]

Posted by "maedhroz (via GitHub)" <gi...@apache.org>.
maedhroz closed pull request #4768: CASSANDRA-21332 Ensure SAI sends range tombstones to the coordinator for queries on static columns
URL: https://github.com/apache/cassandra/pull/4768


-- 
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: pr-unsubscribe@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


Re: [PR] CASSANDRA-21332 Ensure SAI sends range tombstones to the coordinator for queries on static columns [cassandra]

Posted by "adelapena (via GitHub)" <gi...@apache.org>.
adelapena commented on code in PR #4768:
URL: https://github.com/apache/cassandra/pull/4768#discussion_r3138175533


##########
src/java/org/apache/cassandra/index/sai/plan/StorageAttachedIndexSearcher.java:
##########
@@ -539,10 +542,15 @@ private static List<Row> filterPartition(UnfilteredRowIterator partition, Filter
 
                 if (tree.isSatisfiedBy(partitionKey, (Row) unfiltered, staticRow))
                 {
-                    matches.add((Row) unfiltered);
+                    matches.add(unfiltered);
                     hasMatch = true;
                 }
             }
+            else if (matchTombstones && unfiltered.isRangeTombstoneMarker())
+            {
+                // Note that range tombstones to not constitute matches, and will be discarded if no actual rows match.

Review Comment:
   ```suggestion
                   // Note that range tombstones do not constitute matches, and will be discarded if no actual rows match.
   ```



##########
test/distributed/org/apache/cassandra/distributed/test/sai/ReplicaFilteringWithStaticsTest.java:
##########
@@ -158,6 +158,47 @@ public void testMissingStaticRowWithNonStaticExpression(boolean sai)
         assertRows(CLUSTER.coordinator(1).execute(select, ConsistencyLevel.ALL), row(0, 1, 2, 6, 7));
     }
 
+    @Test
+    public void testRangeTombstoneWithStaticSAI()
+    {
+        testRangeTombstoneWithStatic(true);
+    }
+
+    @Test
+    public void testRangeTombstoneWithStatic()
+    {
+        testRangeTombstoneWithStatic(false);
+    }
+
+    public void testRangeTombstoneWithStatic(boolean sai)

Review Comment:
   ```suggestion
       private void testRangeTombstoneWithStatic(boolean sai)
   ```



-- 
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: pr-unsubscribe@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


Re: [PR] CASSANDRA-21332 Ensure SAI sends range tombstones to the coordinator for queries on static columns [cassandra]

Posted by "maedhroz (via GitHub)" <gi...@apache.org>.
maedhroz commented on PR #4768:
URL: https://github.com/apache/cassandra/pull/4768#issuecomment-4329411352

   Committed as https://github.com/apache/cassandra/commits/cassandra-5.0/


-- 
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: pr-unsubscribe@cassandra.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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