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


##########
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/rest/RestServer.java:
##########
@@ -226,20 +235,20 @@ protected final void initializeResources() {
         if (adminListeners == null) {
             log.info("Adding admin resources to main listener");
             adminResourceConfig = resourceConfig;
-            Collection<ConnectResource> adminResources = adminResources();
-            resources.addAll(adminResources);
+            Collection<Class<?>> adminResources = adminResources();
             adminResources.forEach(adminResourceConfig::register);
             configureAdminResources(adminResourceConfig);
         } else if (adminListeners.size() > 0) {
             // TODO: we need to check if these listeners are same as 
'listeners'
             // TODO: the following code assumes that they are different
             log.info("Adding admin resources to admin listener");
             adminResourceConfig = new ResourceConfig();
+            adminResourceConfig.register(requestTimeout.binder());
             adminResourceConfig.register(new JacksonJsonProvider());
-            Collection<ConnectResource> adminResources = adminResources();
-            resources.addAll(adminResources);
+            Collection<Class<?>> adminResources = adminResources();
             adminResources.forEach(adminResourceConfig::register);
             adminResourceConfig.register(ConnectExceptionMapper.class);
+            
adminResourceConfig.property(ServerProperties.WADL_FEATURE_DISABLE, true);

Review Comment:
   This fixes another spurious warning message that gets emitted if the worker 
is configured with the `admin.listeners` property.



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