gortiz commented on code in PR #10184:
URL: https://github.com/apache/pinot/pull/10184#discussion_r1153291384


##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/index/loader/ForwardIndexHandler.java:
##########
@@ -438,10 +442,9 @@ private void 
rewriteRawForwardIndexForCompressionChange(String column, SegmentDi
   }
 
   private void rewriteRawMVForwardIndexForCompressionChange(String column, 
ColumnMetadata existingColMetadata,
-      File indexDir, SegmentDirectory.Writer segmentWriter, 
IndexCreatorProvider indexCreatorProvider,
-      ChunkCompressionType newCompressionType)
+      File indexDir, SegmentDirectory.Writer segmentWriter, 
ChunkCompressionType newCompressionType)
       throws Exception {
-    try (ForwardIndexReader reader = 
LoaderUtils.getForwardIndexReader(segmentWriter, existingColMetadata)) {
+    try (ForwardIndexReader<?> reader = 
ForwardIndexType.getReader(segmentWriter, existingColMetadata)) {

Review Comment:
   Nope, because `StandardIndexes.forward()` returns a `IndexType<...>`, which 
does not have the `getReader` method (now called `read`). And we cannot add 
that method in `IndexType` because not all indexes can be read without 
providing a `FieldIndexConfigs`. We also cannot return `ForwardIndexType` when 
calling `StandardIndexes.standard()` because `StandardIndexes` is in 
`pinot-segment-spi` project while `ForwardIndexType` is in 
`pinot-segment-local`. And we cannot move `ForwardIndexType` to 
`pinot-segment-spi` because it has tons of direct and indirect dependencies to 
`pinot-segment-local`.



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