This is an automated email from the ASF dual-hosted git repository.

ulyssesyou 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 866e4d1f0 [KYUUBI #2683] Add INFO log in 
ServiceDiscovery.stopGracefully
866e4d1f0 is described below

commit 866e4d1f069a8237dc36b3316da77df65678abf8
Author: sychen <[email protected]>
AuthorDate: Wed May 18 20:35:57 2022 +0800

    [KYUUBI #2683] Add INFO log in ServiceDiscovery.stopGracefully
    
    ### _Why are the changes needed?_
    close #2683
    
    Once the administrator starts to stop the server or engine, there is no 
intuitive log to tell the administrator, the number of open sessions now.
    
    ### _How was this patch tested?_
    - [ ] Add some test cases that check the changes thoroughly including 
negative and positive cases if possible
    
    - [x] Add screenshots for manual tests if appropriate
    
    - [x] [Run 
test](https://kyuubi.apache.org/docs/latest/develop_tools/testing.html#running-tests)
 locally before make a pull request
    
    Closes #2684 from cxzl25/KYUUBI-2683.
    
    Closes #2683
    
    19094c23 [sychen] use INFO level
    
    Authored-by: sychen <[email protected]>
    Signed-off-by: ulysses-you <[email protected]>
---
 .../src/main/scala/org/apache/kyuubi/ha/client/ServiceDiscovery.scala | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/kyuubi-ha/src/main/scala/org/apache/kyuubi/ha/client/ServiceDiscovery.scala 
b/kyuubi-ha/src/main/scala/org/apache/kyuubi/ha/client/ServiceDiscovery.scala
index 5dc50dc1f..76215a7b9 100644
--- 
a/kyuubi-ha/src/main/scala/org/apache/kyuubi/ha/client/ServiceDiscovery.scala
+++ 
b/kyuubi-ha/src/main/scala/org/apache/kyuubi/ha/client/ServiceDiscovery.scala
@@ -63,8 +63,8 @@ abstract class ServiceDiscovery(
 
   // stop the server genteelly
   def stopGracefully(isLost: Boolean = false): Unit = {
-    while (fe.be != null && fe.be.sessionManager.getOpenSessionCount > 0) {
-      debug(s"${fe.be.sessionManager.getOpenSessionCount} connection(s) are 
active, delay shutdown")
+    while (fe.be.sessionManager.getOpenSessionCount > 0) {
+      info(s"${fe.be.sessionManager.getOpenSessionCount} connection(s) are 
active, delay shutdown")
       Thread.sleep(1000 * 60)
     }
     isServerLost.set(isLost)

Reply via email to