This is an automated email from the ASF dual-hosted git repository.
zhangbutao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hive.git
The following commit(s) were added to refs/heads/master by this push:
new bdc8995846a HIVE-28514: Addendum: Fix new added iceberg class code
style (#5448)(Butao Zhang, reviewed by Ayush Saxena)
bdc8995846a is described below
commit bdc8995846a4a6873001bd52cd46f9c9969d3630
Author: Butao Zhang <[email protected]>
AuthorDate: Sat Sep 14 00:34:23 2024 +0800
HIVE-28514: Addendum: Fix new added iceberg class code style (#5448)(Butao
Zhang, reviewed by Ayush Saxena)
---
.../main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java | 2 +-
.../src/main/java/org/apache/iceberg/hadoop/HadoopTableOperations.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git
a/iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java
b/iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java
index c572a9991e8..a78ea2069f4 100644
---
a/iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java
+++
b/iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergStorageHandler.java
@@ -2087,7 +2087,7 @@ public class HiveIcebergStorageHandler implements
HiveStoragePredicateHandler, H
tasks.forEach(task -> {
DataFile file = task.file();
PartitionSpec spec = task.spec();
- if ((latestSpecOnly && file.specId() == tableSpecId) ||
(!latestSpecOnly && file.specId() != tableSpecId)) {
+ if (latestSpecOnly && file.specId() == tableSpecId || !latestSpecOnly
&& file.specId() != tableSpecId) {
PartitionData partitionData =
IcebergTableUtil.toPartitionData(task.partition(), spec.partitionType());
String partName = spec.partitionToPath(partitionData);
Map<String, String> partSpecMap = Maps.newLinkedHashMap();
diff --git
a/iceberg/patched-iceberg-core/src/main/java/org/apache/iceberg/hadoop/HadoopTableOperations.java
b/iceberg/patched-iceberg-core/src/main/java/org/apache/iceberg/hadoop/HadoopTableOperations.java
index 8d71f9c648f..1741f3d5199 100644
---
a/iceberg/patched-iceberg-core/src/main/java/org/apache/iceberg/hadoop/HadoopTableOperations.java
+++
b/iceberg/patched-iceberg-core/src/main/java/org/apache/iceberg/hadoop/HadoopTableOperations.java
@@ -278,7 +278,7 @@ public class HadoopTableOperations implements
TableOperations {
for (FileStatus file : files) {
long modificationTime = file.getModificationTime();
Path path = file.getPath();
- if ((currentMaxVersion - version(path.getName()) > previousVersionsMax)
&&
+ if (currentMaxVersion - version(path.getName()) > previousVersionsMax &&
(now - modificationTime) > ttl) {
dirtyCommits.add(path);
}