From 0a87a254f726bdf6835274efa1e0df2fd028f2ed Mon Sep 17 00:00:00 2001 From: wuchunfu <319355703@qq.com> Date: Fri, 16 Jul 2021 12:45:57 +0800 Subject: [PATCH] [KYUUBI #816] [KYUUBI 813] Fix requestTimeoutUnit in FrontendService Fix requestTimeoutUnit in FrontendService #813 ### _How was this patch tested?_ - [ ] Add some test cases that check the changes thoroughly including negative and positive cases if possible - [ ] Add screenshots for manual tests if appropriate - [ ] [Run test](https://kyuubi.readthedocs.io/en/latest/tools/testing.html#running-tests) locally before make a pull request Closes #816 from wuchunfu/813. Closes #816 d15797ca [wuchunfu] [KYUUBI 813] Fix requestTimeoutUnit in FrontendService Authored-by: wuchunfu <319355703@qq.com> Signed-off-by: Kent Yao --- .../scala/org/apache/kyuubi/service/FrontendService.scala | 2 +- .../org/apache/kyuubi/client/KyuubiSyncThriftClient.scala | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 kyuubi-main/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala diff --git a/kyuubi-common/src/main/scala/org/apache/kyuubi/service/FrontendService.scala b/kyuubi-common/src/main/scala/org/apache/kyuubi/service/FrontendService.scala index ec0c2306c..afeb33dab 100644 --- a/kyuubi-common/src/main/scala/org/apache/kyuubi/service/FrontendService.scala +++ b/kyuubi-common/src/main/scala/org/apache/kyuubi/service/FrontendService.scala @@ -88,7 +88,7 @@ class FrontendService private (name: String, be: BackendService, oomHook: Runnab .protocolFactory(new TBinaryProtocol.Factory) .inputProtocolFactory( new TBinaryProtocol.Factory(true, true, maxMessageSize, maxMessageSize)) - .requestTimeout(requestTimeout).requestTimeoutUnit(TimeUnit.SECONDS) + .requestTimeout(requestTimeout).requestTimeoutUnit(TimeUnit.MILLISECONDS) .beBackoffSlotLength(beBackoffSlotLength) .beBackoffSlotLengthUnit(TimeUnit.MILLISECONDS) .executorService(executor) diff --git a/kyuubi-main/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala b/kyuubi-main/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala new file mode 100644 index 000000000..3b0524855 --- /dev/null +++ b/kyuubi-main/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala @@ -0,0 +1,5 @@ +package org.apache.kyuubi.client + +class KyuubiSyncThriftClient { + +}