Skip to content

Conversation

@tsreaper
Copy link
Contributor

Purpose

In #3731 we introduce IcebergCommitCallback to create Iceberg metadata. In this PR we improve this class so that it can reuse Iceberg manifest files created before to create new Iceberg metadata.

Tests

Unit tests.

API and Format

No changes in Paimon format.

Documentation

Document will be added later.

if (baseSnapshot == null) {
createMetadataWithoutBase(currentSnapshot);
} else {
createMetadataWithBase(committable, currentSnapshot, baseSnapshot);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pass Set<BinaryRow> modifiedPartitions to createMetadataWithBase.

.dataSplits();
Map<String, Pair<RawFile, BinaryRow>> currentRawFiles = new HashMap<>();
for (DataSplit dataSplit : dataSplits) {
if (dataSplit.rawConvertible() && modifiedPartitions.contains(dataSplit.partition())) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

without deletion vectors, please add tests.

}
}

public static Object toObject(DataType type, byte[] bytes) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

toPaimonObject?

Copy link
Contributor

@JingsongLi JingsongLi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

Let's keep moving forward!

@JingsongLi JingsongLi merged commit 13bf95b into apache:master Aug 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants