blerer commented on code in PR #3095:
URL: https://github.com/apache/cassandra/pull/3095#discussion_r1590700397


##########
src/java/org/apache/cassandra/cql3/restrictions/RestrictionSetWrapper.java:
##########
@@ -54,25 +52,26 @@ public void addToRowFilter(RowFilter filter,
         restrictions.addToRowFilter(filter, indexRegistry, options);
     }
 
-    public List<ColumnMetadata> getColumnDefs()
+    public List<ColumnMetadata> columns()
     {
-        return restrictions.getColumnDefs();
+        return restrictions.columns();
     }
 
-    @Override
-    public Collection<ColumnMetadata> getColumnDefinitions()

Review Comment:
   The method is not needed any more. The patch changed the logic. Instead of 
iterating over the columns it uses the internal maps to locate the restrictions 
an check their type. It should be more efficient than the previous approach.
   It seems that this information could be precomputed at preparation time and 
stored. I will keep it in mind for the next round of refactoring.



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