felixYyu opened a new issue, #4498:
URL: https://github.com/apache/iceberg/issues/4498
In ALL iceberg project,Static variables are directly embedded in the code
segment, which is not conducive to maintenance.
Do need to formulate a unified rule?
> e.g. BaseRewriteManifestsSparkAction
```
@Override
public RewriteManifests.Result execute() {
String desc = String.format("Rewriting manifests (staging location=%s)
of %s", stagingLocation, table.name());
JobGroupInfo info = newJobGroupInfo("**REWRITE-MANIFESTS**", desc);
return withJobGroupInfo(info, this::doExecute);
}
private Dataset<Row> buildManifestEntryDF(List<ManifestFile> manifests) {
Dataset<Row> manifestDF = spark()
.createDataset(Lists.transform(manifests, ManifestFile::path),
Encoders.STRING())
.toDF("**manifest**");
Dataset<Row> manifestEntryDF = loadMetadataTable(table, ENTRIES)
.filter("status < 2") // select only live entries
.selectExpr("input_file_name() as manifest", "**snapshot_id**",
"**sequence_number**", "**data_file**");
Column joinCond =
manifestDF.col("manifest").equalTo(manifestEntryDF.col("**manifest**"));
return manifestEntryDF
.join(manifestDF, joinCond, "**left_semi**")
.select("**snapshot_id**", "**sequence_number**", "**data_file**");
}
```
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]