rdblue commented on a change in pull request #2343:
URL: https://github.com/apache/iceberg/pull/2343#discussion_r604314442
##########
File path: core/src/main/java/org/apache/iceberg/BaseFile.java
##########
@@ -169,13 +167,12 @@ public PartitionData copy() {
this.recordCount = toCopy.recordCount;
this.fileSizeInBytes = toCopy.fileSizeInBytes;
if (fullCopy) {
- // TODO: support lazy conversion to/from map
- this.columnSizes = copy(toCopy.columnSizes);
- this.valueCounts = copy(toCopy.valueCounts);
- this.nullValueCounts = copy(toCopy.nullValueCounts);
- this.nanValueCounts = copy(toCopy.nanValueCounts);
- this.lowerBounds =
SerializableByteBufferMap.wrap(copy(toCopy.lowerBounds));
- this.upperBounds =
SerializableByteBufferMap.wrap(copy(toCopy.upperBounds));
+ this.columnSizes = SerializableMap.copyOf(toCopy.columnSizes);
+ this.valueCounts = SerializableMap.copyOf(toCopy.valueCounts);
+ this.nullValueCounts = SerializableMap.copyOf(toCopy.nullValueCounts);
+ this.nanValueCounts = SerializableMap.copyOf(toCopy.nanValueCounts);
+ this.lowerBounds =
SerializableByteBufferMap.wrap(SerializableMap.copyOf(toCopy.lowerBounds));
Review comment:
Later, we should check whether we need two wrappers, but it isn't a
blocker here.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]