omalley commented on a change in pull request #810:
URL: https://github.com/apache/orc/pull/810#discussion_r682128050



##########
File path: java/core/src/java/org/apache/orc/impl/ReaderImpl.java
##########
@@ -569,7 +561,13 @@ public ReaderImpl(Path path, OrcFile.ReaderOptions 
options) throws IOException {
       this.rowIndexStride = tail.getFooter().getRowIndexStride();
       this.contentLength = tail.getFooter().getContentLength();
       this.numberOfRows = tail.getFooter().getNumberOfRows();
-      this.userMetadata = tail.getFooter().getMetadataList();
+      this.userMetadata = tail.getFooter().getMetadataList()
+              .stream().collect(Collectors.toMap(

Review comment:
       The java stream apis are very slow. It would perform better if you used 
a loop. This is especially important, because now the set is build 
preemptively, even if the user doesn't need the metadata values.




-- 
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: dev-unsubscr...@orc.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to