C0urante commented on code in PR #12290:
URL: https://github.com/apache/kafka/pull/12290#discussion_r1237620493


##########
connect/runtime/src/test/java/org/apache/kafka/connect/integration/BlockingConnectorTest.java:
##########
@@ -350,13 +353,16 @@ private void assertRequestTimesOut(String 
requestDescription, ThrowingRunnable r
     }
 
     private static class Block {
-        private static CountDownLatch blockLatch;
+        // All latches that blocking connectors/tasks are or will be waiting 
on during a test case
+        private static final Set<CountDownLatch> BLOCK_LATCHES = new 
HashSet<>();
+        // The latch that can be used to wait for a connector/task to reach 
the most-recently-registered blocking point
+        private static CountDownLatch awaitBlockLatch;
 
         private final String block;
 
         public static final String BLOCK_CONFIG = "block";
 
-        private static ConfigDef config() {
+        public static ConfigDef config() {

Review Comment:
   It signals that the method is used outside of the class in which it's 
defined (even though in this case, as you noted, it's not required since the 
outer class can still access `private` methods), and makes it easier to pull 
the inner `Block` class out into a separate top-level class if necessary.
   
   I was hoping this would help with readability, but if it's more confusing 
than useful, we should definitely revert. Thoughts?



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