philipnee commented on code in PR #16629:
URL: https://github.com/apache/kafka/pull/16629#discussion_r1688563938


##########
clients/src/main/java/org/apache/kafka/clients/NetworkClient.java:
##########
@@ -1106,6 +1125,104 @@ private boolean isTelemetryApi(ApiKeys apiKey) {
         return apiKey == ApiKeys.GET_TELEMETRY_SUBSCRIPTIONS || apiKey == 
ApiKeys.PUSH_TELEMETRY;
     }
 
+    public static class BootstrapConfiguration {
+        public final List<String> bootstrapServers;
+        public final ClientDnsLookup clientDnsLookup;
+        public final long bootstrapResolveTimeoutMs;
+        private final boolean bootstrapDisabled;
+
+        public BootstrapConfiguration(final List<String> bootstrapServers,
+                                      final ClientDnsLookup clientDnsLookup,
+                                      final long bootstrapResolveTimeoutMs) {
+            this.bootstrapServers = bootstrapServers;
+            this.clientDnsLookup = clientDnsLookup;
+            this.bootstrapResolveTimeoutMs = bootstrapResolveTimeoutMs;
+            this.bootstrapDisabled = false;
+        }
+    }
+
+    private class BootstrapState {
+        private final Timer timer;
+        private final List<String> bootstrapServers;
+        private final ClientDnsLookup clientDnsLookup;
+        private final long dnsResolutionTimeoutMs;
+        private final boolean isDisabled;
+        private boolean isBootstrapped;
+
+        BootstrapState(BootstrapConfiguration bootstrapConfiguration) {

Review Comment:
   or just make bootstrapConfiguration Optional<BootstrapConfiguration> so we 
don't need to check isDisabled and isBootstrapped



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