maedhroz commented on code in PR #4353:
URL: https://github.com/apache/cassandra/pull/4353#discussion_r2683627193


##########
src/java/org/apache/cassandra/index/sai/disk/v1/segment/IndexSegmentSearcher.java:
##########
@@ -84,6 +88,20 @@ else if (index.termType().isLiteral())
      */
     public abstract KeyRangeIterator search(Expression expression, 
AbstractBounds<PartitionPosition> keyRange, QueryContext queryContext) throws 
IOException;
 
+    /**
+     * Order the rows by the given expression.
+     *
+     * @param exp      the object containing the ordering logic
+     * @param keyRange key range specific in read command, used by ANN index
+     * @param context  to track per sstable cache and per query metrics
+     * @return an iterator of {@link PrimaryKeyWithScore} in descending score 
order
+     */
+    public CloseableIterator<PrimaryKeyWithScore> orderBy(Expression exp, 
AbstractBounds<PartitionPosition> keyRange, QueryContext context) throws 
IOException

Review Comment:
   Yeah, I guess the best we can do for readability is name the thing what it 
actually is regardless of the type and go from there.



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