maedhroz commented on code in PR #3890: URL: https://github.com/apache/cassandra/pull/3890#discussion_r1951921356
########## src/java/org/apache/cassandra/index/sai/plan/QueryController.java: ########## @@ -288,7 +288,10 @@ public KeyRangeIterator.Builder getIndexQueryResults(Collection<Expression> expr private void maybeTriggerGuardrails(QueryViewBuilder.QueryView queryView) { - int referencedIndexes = queryView.referencedIndexes.size(); + int referencedIndexes = 0; + + for (Pair<Expression, Collection<SSTableIndex>> expressionSSTables : queryView.view) + referencedIndexes = Math.max(referencedIndexes, expressionSSTables.right.size()); Review Comment: This guardrail was designed to make sure individual column predicates don't involve index queries that hit too many SSTables rather than worrying about the total number of SSTables across all column predicates. The Harry tests can have 10+ column predicates, and that makes it much more likely we'll hit this and give in-JVM tests trouble. -- 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-unsubscr...@cassandra.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org For additional commands, e-mail: pr-h...@cassandra.apache.org