You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "aokolnychyi (via GitHub)" <gi...@apache.org> on 2023/05/19 01:16:17 UTC
[GitHub] [iceberg] aokolnychyi commented on a diff in pull request #7650: Spark 3.4: Cosmetic updates for SparkPositionDeltaWrite
aokolnychyi commented on code in PR #7650:
URL: https://github.com/apache/iceberg/pull/7650#discussion_r1198453557
##########
spark/v3.4/spark/src/main/java/org/apache/iceberg/spark/source/SparkPositionDeltaWrite.java:
##########
@@ -386,10 +384,14 @@ protected InternalRowWrapper initPartitionRowWrapper(Types.StructType partitionT
protected Map<Integer, StructProjection> buildPartitionProjections(
Types.StructType partitionType, Map<Integer, PartitionSpec> specs) {
Map<Integer, StructProjection> partitionProjections = Maps.newHashMap();
- specs.forEach(
- (specID, spec) ->
- partitionProjections.put(
- specID, StructProjection.create(partitionType, spec.partitionType())));
+
+ for (Map.Entry<Integer, PartitionSpec> entry : specs.entrySet()) {
Review Comment:
I like it, even though it does an extra lookup. Changed.
--
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