ruanwenjun opened a new pull request, #7527:
URL: https://github.com/apache/kyuubi/pull/7527

   ### Why are the changes needed?
   
   JDBC clients can block inside `KyuubiConnection` construction while waiting 
for engine launch. If the caller cancels that connection attempt with 
`Thread.interrupt()`, the wait loop previously kept polling and the caller 
still had no returned `Connection` object to close.
   
   This patch makes the launch wait path honor interruption by converting it to 
a typed JDBC exception, `KyuubiInterruptedException`. The interrupt status is 
intentionally consumed before the exception reaches the caller, and comments 
explain that the caller receives the typed exception while the current thread 
is not interrupted.
   
   The patch also keeps `SQLException` subclasses intact when 
`KyuubiDataSource` creates a connection, so callers can distinguish the 
interrupted launch path.
   
   ### How was this patch tested?
   
   - `./build/mvn -pl kyuubi-hive-jdbc -am spotless:apply`
   - `./build/mvn -pl kyuubi-hive-jdbc -am 
-Dtest=KyuubiConnectionTest,KyuubiStatementTest,TestJdbcDriver,TestKyuubiPreparedStatement,UtilsTest,ZooKeeperHiveClientHelperTest
 -DwildcardSuites=none test`
   - `git diff --check`
   
   Also attempted `dev/reformat`, but the full repo reformat is blocked in this 
local environment because Spotless expects `black 22.3.0` while the installed 
executable is `black 25.1.0`.
   
   ### Was this patch authored or co-authored using generative AI tooling?
   
   Assisted-by: OpenAI Codex: GPT-5
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to