From 8a877afe98709989a880afe28f18bb0090a8a7bc Mon Sep 17 00:00:00 2001 From: wangjunbo Date: Tue, 20 Feb 2024 20:05:59 +0800 Subject: [PATCH] fix test --- docs/configuration/settings.md | 2 +- .../main/scala/org/apache/kyuubi/config/KyuubiConf.scala | 2 +- .../kyuubi/operation/KyuubiRestAuthenticationSuite.scala | 6 ++++-- 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/configuration/settings.md b/docs/configuration/settings.md index 663043e61d5..df42b153ead 100644 --- a/docs/configuration/settings.md +++ b/docs/configuration/settings.md @@ -246,7 +246,7 @@ You can configure the Kyuubi properties in `$KYUUBI_HOME/conf/kyuubi-defaults.co | kyuubi.frontend.mysql.worker.keepalive.time | PT1M | Time(ms) that an idle async thread of the command execution thread pool will wait for a new task to arrive before terminating in MySQL frontend service | duration | 1.4.0 | | kyuubi.frontend.protocols | THRIFT_BINARY,REST | A comma-separated list for all frontend protocols | seq | 1.4.0 | | kyuubi.frontend.proxy.http.client.ip.header | X-Real-IP | The HTTP header to record the real client IP address. If your server is behind a load balancer or other proxy, the server will see this load balancer or proxy IP address as the client IP address, to get around this common issue, most load balancers or proxies offer the ability to record the real remote IP address in an HTTP header that will be added to the request for other devices to use. Note that, because the header value can be specified to any IP address, so it will not be used for authentication. | string | 1.6.0 | -| kyuubi.frontend.rest.authentication | NONE | A comma-separated list of client authentication types. It fallback to `kyuubi.authentication` if not configure. | seq | 1.9.0 | +| kyuubi.frontend.rest.authentication | NONE | A comma-separated list of rest protocol client authentication types. It fallback to `kyuubi.authentication` if not configure. | seq | 1.9.0 | | kyuubi.frontend.rest.bind.host | <undefined> | Hostname or IP of the machine on which to run the REST frontend service. | string | 1.4.0 | | kyuubi.frontend.rest.bind.port | 10099 | Port of the machine on which to run the REST frontend service. | int | 1.4.0 | | kyuubi.frontend.rest.max.worker.threads | 999 | Maximum number of threads in the frontend worker thread pool for the rest frontend service | int | 1.6.2 | diff --git a/kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala b/kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala index c943823133b..136cd10c840 100644 --- a/kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala +++ b/kyuubi-common/src/main/scala/org/apache/kyuubi/config/KyuubiConf.scala @@ -799,7 +799,7 @@ object KyuubiConf { val FRONTEND_REST_AUTHENTICATION_METHOD: ConfigEntry[Seq[String]] = buildConf("kyuubi.frontend.rest.authentication") - .doc("A comma-separated list of client authentication types." + + .doc("A comma-separated list of rest protocol client authentication types." + " It fallback to `kyuubi.authentication` if not configure.") .version("1.9.0") .serverOnly diff --git a/kyuubi-server/src/test/scala/org/apache/kyuubi/operation/KyuubiRestAuthenticationSuite.scala b/kyuubi-server/src/test/scala/org/apache/kyuubi/operation/KyuubiRestAuthenticationSuite.scala index 965e4ccd669..fb9e574ba61 100644 --- a/kyuubi-server/src/test/scala/org/apache/kyuubi/operation/KyuubiRestAuthenticationSuite.scala +++ b/kyuubi-server/src/test/scala/org/apache/kyuubi/operation/KyuubiRestAuthenticationSuite.scala @@ -186,7 +186,9 @@ class KyuubiRestAuthenticationSuite extends RestClientTestHelper { class NoneKyuubiRestAuthenticationSuite extends RestClientTestHelper { override protected val otherConfigs: Map[String, String] = { - Map(KyuubiConf.FRONTEND_REST_AUTHENTICATION_METHOD.key -> "NONE") + Map( + KyuubiConf.AUTHENTICATION_METHOD.key -> "KERBEROS", + KyuubiConf.FRONTEND_REST_AUTHENTICATION_METHOD.key -> "NONE") } test("test disable restful api authentication") { @@ -201,7 +203,7 @@ class NoneKyuubiRestAuthenticationSuite extends RestClientTestHelper { class KerberosKyuubiRestAuthenticationSuite extends RestClientTestHelper { override protected val otherConfigs: Map[String, String] = { - Map(KyuubiConf.FRONTEND_REST_AUTHENTICATION_METHOD.key -> "KERBEROS") + Map(KyuubiConf.AUTHENTICATION_METHOD.key -> "KERBEROS") } test("test without authorization when rest api authentication with KERBEROS") {