From 8cb81873b4190a35966a31387944a37a7b879145 Mon Sep 17 00:00:00 2001 From: Igor Khrol Date: Mon, 12 May 2025 12:57:27 +0800 Subject: [PATCH] [KYUUBI #7051] Fix usage without sslTrustStore of JDBC driver ### Why are the changes needed? If `sslTrustStore` is not provided `org.apache.hadoop.conf.Configuration` class existence becomes a hard dependency. This makes jdbc client too complex to configure: extra Hadoop jars should be provided. `hadoopCredentialProviderAvailable` variable is useless in the previous implementation logic because it's always `true` or the code is not reachable. Screenshot 2025-05-09 at 13 05 12 ### How was this patch tested? Build jar and used it to connect from DataGrip. Screenshot 2025-05-09 at 13 01 29 ### Was this patch authored or co-authored using generative AI tooling? No. Closes #7058 from Khrol/master. Closes #7051 b594757a0 [Igor Khrol] JDBC driver: allow usage without sslTrustStore Authored-by: Igor Khrol Signed-off-by: Cheng Pan (cherry picked from commit 61487acfa022ad9abfc538ed8b63fd02acc3a628) Signed-off-by: Cheng Pan --- .../src/main/java/org/apache/kyuubi/jdbc/hive/Utils.java | 1 - 1 file changed, 1 deletion(-) diff --git a/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/Utils.java b/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/Utils.java index 86b397437..39e5275a5 100644 --- a/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/Utils.java +++ b/kyuubi-hive-jdbc/src/main/java/org/apache/kyuubi/jdbc/hive/Utils.java @@ -669,7 +669,6 @@ public class Utils { hadoopCredentialProviderAvailable = true; } catch (Exception exception) { LOG.warn("Hadoop credential provider is unavailable", exception); - throw new RuntimeException(exception); } } if (password == null && hadoopCredentialProviderAvailable) {