kkrugler commented on code in PR #8802:
URL: https://github.com/apache/pinot/pull/8802#discussion_r885097953
##########
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/utils/IngestionUtils.java:
##########
@@ -240,7 +240,7 @@ public static void uploadSegment(String tableNameWithType,
BatchConfig batchConf
}
PinotFS outputFileFS = getOutputPinotFS(batchConfig,
outputSegmentDirURI);
Map<String, String> segmentUriToTarPathMap =
SegmentPushUtils.getSegmentUriToTarPathMap(outputSegmentDirURI,
- segmentUploadSpec.getPushJobSpec(), new String[] {
segmentTarURIs.toString() });
+ segmentUploadSpec.getPushJobSpec(),
segmentTarURIStrs.toArray(String[]::new));
Review Comment:
I had made the most recent change to this line with my commit
`f12e62522b8d09c8525a7482c92141042e3155c2`, but the logic of passing `new
String[] { blah }` as the parameter was from the initial commit of this code in
2021. So two questions are:
1. Is there a test to demonstrate the issue with the original code, and
2. What about all the other places where this same code also exists? See
`HadoopSegmentMetadataPushJobRunner.java`,
`SparkSegmentMetadataPushJobRunner.java`, etc.
Item 2 does suggest some refactoring would be in order...
--
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]