You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2022/02/11 22:54:03 UTC

[GitHub] [pinot] dongxiaoman commented on a change in pull request #8193: Enable service discovery in controller too

dongxiaoman commented on a change in pull request #8193:
URL: https://github.com/apache/pinot/pull/8193#discussion_r805057238



##########
File path: pinot-core/src/main/java/org/apache/pinot/core/api/ServiceAutoDiscoveryFeature.java
##########
@@ -68,8 +69,8 @@
  * pinot-integration-tests/src/main/java/org/apache/pinot/broker/integration/tests/BrokerTestAutoLoadedService.java
  * </code>
  */
-public class BrokerServiceAutoDiscoveryFeature implements Feature {
-    private static final Logger LOGGER = LoggerFactory.getLogger(BrokerServiceAutoDiscoveryFeature.class);
+public class ServiceAutoDiscoveryFeature implements Feature {

Review comment:
       A very good point. I added some code (static boolean) to make sure discovery is done once per JVM, and did the integration test that starts Broker+Controller in the same test.
   The result shows that only one of the Broker/Controller can find service properly.
   It seems that based on Jersey, Services/Features are isolated per `Application` (tied to ResourceConfig) level, so if there are two applications, the discovery has to be done twice.
   




-- 
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: commits-unsubscribe@pinot.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org