From 66755c0cd20b7c525daf57e7c05c64c019a133cb Mon Sep 17 00:00:00 2001 From: Duo Zhang Date: Wed, 22 Jun 2022 22:38:12 +0800 Subject: [PATCH] HBASE-27141 Upgrade hbase-thirdparty dependency to 4.1.1 (#4552) Signed-off-by: Andrew Purtell Signed-off-by: Pankaj Kumar (cherry picked from commit 9bae50f83c6c300d8952527bece28c3d2c13e179) --- .../apache/hadoop/hbase/http/HttpServer.java | 5 +- .../apache/hadoop/hbase/util/JSONBean.java | 2 +- hbase-protocol-shaded/pom.xml | 4 +- .../apache/hadoop/hbase/thrift/Constants.java | 5 +- pom.xml | 274 +++++++++++++++++- 5 files changed, 275 insertions(+), 15 deletions(-) diff --git a/hbase-http/src/main/java/org/apache/hadoop/hbase/http/HttpServer.java b/hbase-http/src/main/java/org/apache/hadoop/hbase/http/HttpServer.java index f3f6025ecbd9..9b910c1676e8 100644 --- a/hbase-http/src/main/java/org/apache/hadoop/hbase/http/HttpServer.java +++ b/hbase-http/src/main/java/org/apache/hadoop/hbase/http/HttpServer.java @@ -108,7 +108,10 @@ public class HttpServer implements FilterContainer { private static final Logger LOG = LoggerFactory.getLogger(HttpServer.class); private static final String EMPTY_STRING = ""; - private static final int DEFAULT_MAX_HEADER_SIZE = 64 * 1024; // 64K + // Jetty's max header size is Character.MAX_VALUE - 1, See ArrayTernaryTrie for more details + // And in newer jetty version, they add a check when creating a server so we must follow this + // limitation otherwise the UTs will fail + private static final int DEFAULT_MAX_HEADER_SIZE = Character.MAX_VALUE - 1; static final String FILTER_INITIALIZERS_PROPERTY = "hbase.http.filter.initializers"; diff --git a/hbase-http/src/main/java/org/apache/hadoop/hbase/util/JSONBean.java b/hbase-http/src/main/java/org/apache/hadoop/hbase/util/JSONBean.java index def2611b3a5f..98af1609984a 100644 --- a/hbase-http/src/main/java/org/apache/hadoop/hbase/util/JSONBean.java +++ b/hbase-http/src/main/java/org/apache/hadoop/hbase/util/JSONBean.java @@ -57,7 +57,7 @@ public class JSONBean { private static final String COMMA = ","; private static final String ASTERICK = "*"; private static final Logger LOG = LoggerFactory.getLogger(JSONBean.class); - private static final Gson GSON = GsonUtil.createGson().create(); + private static final Gson GSON = GsonUtil.createGsonWithDisableHtmlEscaping().create(); /** * Use dumping out mbeans as JSON. diff --git a/hbase-protocol-shaded/pom.xml b/hbase-protocol-shaded/pom.xml index 26be663e2f91..7af6236229f8 100644 --- a/hbase-protocol-shaded/pom.xml +++ b/hbase-protocol-shaded/pom.xml @@ -33,8 +33,8 @@ true - 3.11.4 + --> + 3.21.1 diff --git a/hbase-thrift/src/main/java/org/apache/hadoop/hbase/thrift/Constants.java b/hbase-thrift/src/main/java/org/apache/hadoop/hbase/thrift/Constants.java index 930dfe45800d..fcb7651fc332 100644 --- a/hbase-thrift/src/main/java/org/apache/hadoop/hbase/thrift/Constants.java +++ b/hbase-thrift/src/main/java/org/apache/hadoop/hbase/thrift/Constants.java @@ -26,7 +26,10 @@ public final class Constants { private Constants(){} - public static final int DEFAULT_HTTP_MAX_HEADER_SIZE = 64 * 1024; // 64k + // Jetty's max header size is Character.MAX_VALUE - 1, See ArrayTernaryTrie for more details + // And in newer jetty version, they add a check when creating a server so we must follow this + // limitation otherwise the UTs will fail + public static final int DEFAULT_HTTP_MAX_HEADER_SIZE = Character.MAX_VALUE - 1; public static final String SERVER_TYPE_CONF_KEY = "hbase.regionserver.thrift.server.type"; diff --git a/pom.xml b/pom.xml index 41efae4afa07..598386c3c3d6 100755 --- a/pom.xml +++ b/pom.xml @@ -512,16 +512,270 @@ +8 - - - - kr.motd.maven - os-maven-plugin - ${os.maven.version} - - - + file:///tmp + + + + + false + + false + + false + + false + + false + + false + ${project.build.finalName}.tar.gz + yyyy-MM-dd'T'HH:mm + ${maven.build.timestamp} + 1.8 + 8 + + 3.0.4 + ${compileSource} + + 2.10.0 + 3.1.2 + + ${hadoop-two.version} + 11.0.2 + hbase-hadoop2-compat + src/main/assembly/hadoop-two-compat.xml + + 3.6.2.Final + + 0.5.0 + 1.7.7 + 2.8.1 + 1.13 + 2.11.0 + 3.9 + 3.6.1 + 3.4.2 + 4.5.13 + 4.4.13 + 3.2.6 + 2.13.3 + 2.13.3 + 2.3.1 + 3.1.0 + 2.1.1 + 2.3.2 + 3.0.1-b08 + 9.3.4.0 + 4.13.2 + 1.3 + 1.0.1 + 1.0.1 + 2.17.2 + 2.28.2 + + com.google.protobuf + 2.5.0 + ${external.protobuf.version} + 0.6.1 + thrift + 0.14.1 + 3.5.7 + 2.11 + 1.7.33 + 4.0.3 + 2.4.1 + 1.3.8 + + 2.1.42 + 1.0.56 + 2.12.2 + 1.67 + 1.0.1 + 1.0.0 + 4.2.0 + + 3.0.0 + 1.4 + + 8.29 + 1.6.0 + 2.10.0 + 2.4.2 + 1.0.0 + 1.8 + 3.3.0 + 3.1.0 + 2.10 + 3.0.1 + 3.4.0 + 1.1.0 + 3.1.2 + 1.5.0.Final + 1.3.9-1 + 4.2.2 + 4.2.0 + 3.0.0-M6 + 2.12 + 1.0.1 + 2.22.2 + 3.12.0 + + 0.21 + 1.7.1 + 1.8.0 + 1.1.8.4 + 1.9 + 1.5.0-4 + 4.1.1 + + + hbase-server-${project.version}-tests.jar + hbase-common-${project.version}-tests.jar + hbase-procedure-${project.version}-tests.jar + hbase-it-${project.version}-tests.jar + hbase-annotations-${project.version}-tests.jar + hbase-rsgroup-${project.version}-tests.jar + hbase-mapreduce-${project.version}-tests.jar + hbase-zookeeper-${project.version}-tests.jar + hbase-asyncfs-${project.version}-tests.jar + bash + surefire-junit47 + + false + false + + 0.25C + 0.25C + org.apache.hadoop.hbase.testclassification.SmallTests + org.apache.hadoop.hbase.testclassification.MediumTests + false + true + 900 + + + 2200m + 2200m +