yuqi1129 opened a new issue, #14761:
URL: https://github.com/apache/gravitino/issues/14761

   ### Version
   
   main branch
   
   ### Describe what's wrong
   
   `BoundedConnectionDriver` interrupts the worker thread on the request thread 
when a connection attempt times out or the caller is interrupted. 
`Thread.interrupt()` can synchronously run a driver's interrupt callback, for 
example closing an `InterruptibleChannel` registered by the driver. If that 
callback blocks, the request thread stays blocked past the connection deadline 
that the adapter is supposed to enforce.
   
   ### Error message and/or stacktrace
   
   No error is raised; the caller of `BoundedConnectionDriver#connect` does not 
return at its deadline.
   
   ### How to reproduce
   
   1. Wrap a driver whose `connect` registers an `AbstractInterruptibleChannel` 
whose `implCloseChannel` blocks.
   2. Call `BoundedConnectionDriver#connect` with a short timeout.
   3. The caller blocks in `Thread.interrupt()` instead of failing with 
`SQLTimeoutException` at the deadline.
   
   ### Additional context
   
   The interrupt should be delivered off the request thread, must not reach a 
later attempt that reuses the same pooled worker, and abandoned attempts should 
be observable in logs.
   


-- 
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]

Reply via email to