You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kyuubi.apache.org by ch...@apache.org on 2022/12/19 16:03:22 UTC
[incubator-kyuubi] branch master updated: [KYUUBI #4009] Fix `sendCredentials` wrong log
This is an automated email from the ASF dual-hosted git repository.
chengpan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-kyuubi.git
The following commit(s) were added to refs/heads/master by this push:
new 0f03fb975 [KYUUBI #4009] Fix `sendCredentials` wrong log
0f03fb975 is described below
commit 0f03fb975e30025596f3661b84af79fd6071fdd7
Author: sychen <sy...@ctrip.com>
AuthorDate: Tue Dec 20 00:03:13 2022 +0800
[KYUUBI #4009] Fix `sendCredentials` wrong log
### _Why are the changes needed?_
`KyuubiSyncThriftClient#sendCredentials` did not throw an exception when it failed, `HadoopCredentialsManager#sendCredentialsIfNeeded` thought the send was successful and output a success log.
```
22/12/19 14:45:32,272 [KyuubiSessionManager-exec-pool: Thread-98994]
WARN KyuubiSyncThriftClient: TRenewDelegationTokenReq XXX failed on engine side
22/12/19 14:45:32,273 [KyuubiSessionManager-exec-pool: Thread-98994]
INFO HadoopCredentialsManager: Update session credentials epoch from -1 to 0
```
### _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.apache.org/docs/latest/develop_tools/testing.html#running-tests) locally before make a pull request
Closes #4009 from cxzl25/fix_sendCredentials_wrong_log.
Closes #4009
3ca2ebac [sychen] sendCredentials wrong log
Authored-by: sychen <sy...@ctrip.com>
Signed-off-by: Cheng Pan <ch...@apache.org>
---
.../main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/kyuubi-server/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala b/kyuubi-server/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala
index a5bd425e2..babe73745 100644
--- a/kyuubi-server/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala
+++ b/kyuubi-server/src/main/scala/org/apache/kyuubi/client/KyuubiSyncThriftClient.scala
@@ -419,7 +419,10 @@ class KyuubiSyncThriftClient private (
warn(s"$req failed on engine side", KyuubiSQLException(resp.getStatus))
}
} catch {
- case e: Exception => warn(s"$req failed on engine side", e)
+ case e: Exception =>
+ warn(s"$req failed on engine side", e)
+ // catch exception in HadoopCredentialsManager.sendCredentialsIfNeeded
+ throw e
}
}
}