You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "advancedxy (via GitHub)" <gi...@apache.org> on 2023/08/17 07:56:58 UTC
[GitHub] [iceberg] advancedxy commented on a diff in pull request #8336: Core: Optimize offset splits handling
advancedxy commented on code in PR #8336:
URL: https://github.com/apache/iceberg/pull/8336#discussion_r1296825297
##########
core/src/main/java/org/apache/iceberg/util/ArrayUtil.java:
##########
@@ -59,6 +61,14 @@ public static List<Long> toLongList(long[] longs) {
}
}
+ public static List<Long> toUnmodifiableLongList(long[] longs) {
+ if (longs != null) {
+ return Collections.unmodifiableList(Longs.asList(longs));
Review Comment:
Why not simply use `java.util.Arrays.asList(longs)` instead of Guava's `Longs.asList`? Seems like they have the same characteristic. And the Arrays.asList probably has more chance to get optimization in the newer version of JDKs.
--
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: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org