chia7712 commented on code in PR #20131:
URL: https://github.com/apache/kafka/pull/20131#discussion_r2205585439


##########
server-common/src/main/java/org/apache/kafka/server/util/LockUtils.java:
##########
@@ -115,7 +70,7 @@ public static <T, E extends Exception> T inLockThrows(Lock 
lock, ThrowingSupplie
      * @throws E if an exception occurs during the execution of the runnable
      * @throws NullPointerException if either {@code lock} or {@code runnable} 
is null
      */
-    public static <E extends Exception> void inLockThrows(Lock lock, 
ThrowingRunnable<E> runnable) throws E {
+    public static <E extends Exception> void inLock(Lock lock, 
ThrowingRunnable<E> runnable) throws E {

Review Comment:
   > what does E bind to? RuntimeException?
   
   I think you are right. Quoted from the spec `18.1.3 Bounds`:
   ```
   A bound of the form throws α is purely informational: it directs resolution 
to
   optimize the instantiation of α so that, if possible, it is not a checked 
exception type.
   ```



-- 
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: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to