belugabehr commented on a change in pull request #977:
URL: https://github.com/apache/orc/pull/977#discussion_r774862105



##########
File path: java/core/src/java/org/apache/orc/TypeDescription.java
##########
@@ -565,9 +557,7 @@ public int getScale() {
    * @return a list of sorted attribute names
    */
   public List<String> getAttributeNames() {
-    List<String> result = new ArrayList<>(attributes.keySet());
-    Collections.sort(result);
-    return result;
+    return new ArrayList<>(attributes.keySet());

Review comment:
       Keep the `attributes` Map sorted so it doesn't have to be sorted every 
time this method is invoked.




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