From f33f932e52bdc01230b2a1e5aea5c3cfbb381224 Mon Sep 17 00:00:00 2001 From: Jingsong Date: Mon, 18 Mar 2024 10:12:41 +0800 Subject: [PATCH] [hive] Add license for TezUtil --- LICENSE | 1 + .../java/org/apache/paimon/hive/mapred/TezUtil.java | 11 ++++++----- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/LICENSE b/LICENSE index 97c849402f1d..eb317b6613a4 100644 --- a/LICENSE +++ b/LICENSE @@ -242,6 +242,7 @@ paimon-core/src/main/java/org/apache/paimon/jdbc/JdbcCatalog.java paimon-core/src/main/java/org/apache/paimon/utils/ZOrderByteUtils.java paimon-core/src/test/java/org/apache/paimon/utils/TestZOrderByteUtil.java paimon-hive/paimon-hive-common/src/test/java/org/apache/paimon/hive/TestHiveMetastore.java +paimon-hive/paimon-hive-connector-common/src/main/java/org/apache/paimon/hive/mapred/TezUtil.java paimon-spark/paimon-spark-common/src/main/antlr4/org.apache.spark.sql.catalyst.parser.extensions/PaimonSqlExtensions.g4 paimon-spark/paimon-spark-common/src/main/java/org/apache/paimon/spark/SparkGenericCatalog.java paimon-spark/paimon-spark-common/src/main/scala/org/apache/spark/sql/catalyst/analysis/CoerceArguments.scala diff --git a/paimon-hive/paimon-hive-connector-common/src/main/java/org/apache/paimon/hive/mapred/TezUtil.java b/paimon-hive/paimon-hive-connector-common/src/main/java/org/apache/paimon/hive/mapred/TezUtil.java index d4d7c7cd9c71..99a52798041a 100644 --- a/paimon-hive/paimon-hive-connector-common/src/main/java/org/apache/paimon/hive/mapred/TezUtil.java +++ b/paimon-hive/paimon-hive-connector-common/src/main/java/org/apache/paimon/hive/mapred/TezUtil.java @@ -28,10 +28,11 @@ import java.util.Objects; -/** - * Utility class to enrich the JobContext and TaskAttemptContext with the vertex id. copied form - * iceberg. - */ +/* This file is based on source code from the Iceberg Project (http://iceberg.apache.org/), licensed by the Apache + * Software Foundation (ASF) under the Apache License, Version 2.0. See the NOTICE file distributed with this work for + * additional information regarding copyright ownership. */ + +/** Utility class to enrich the JobContext and TaskAttemptContext with the vertex id. */ public class TezUtil { private static final String TASK_ATTEMPT_ID_KEY = "mapred.task.id"; @@ -96,7 +97,7 @@ private TezUtil() {} /** * Subclasses {@link TaskAttemptID}. It has two main purposes: 1. Provide a way to append an * optional vertex id to the Job ID. This is needed because there is a discrepancy between how - * the attempt ID is constructed in the {@link org.apache.tez.mapreduce.output.MROutput} (with + * the attempt ID is constructed in the {@code org.apache.tez.mapreduce.output.MROutput} (with * vertex ID appended to the end of the Job ID) and how it's available in the mapper (without * vertex ID) which creates and caches the HiveIcebergRecordWriter object. 2. Redefine the * equals/hashcode provided by TaskAttemptID so that task type (map or reduce) does not count,