kfaraz commented on a change in pull request #11766:
URL: https://github.com/apache/druid/pull/11766#discussion_r722016613



##########
File path: server/src/main/java/org/apache/druid/client/BrokerServerView.java
##########
@@ -106,17 +106,34 @@ public BrokerServerView(
     this.baseView = baseView;
     this.tierSelectorStrategy = tierSelectorStrategy;
     this.emitter = emitter;
-    this.segmentWatcherConfig = segmentWatcherConfig;
     this.clients = new ConcurrentHashMap<>();
     this.selectors = new HashMap<>();
     this.timelines = new HashMap<>();
 
+    // Validate and set the segment watcher config
+    this.segmentWatcherConfig = segmentWatcherConfig;
+    if (segmentWatcherConfig.getWatchedTiers() != null

Review comment:
       Do you think it would make sense to add a `validate` method in 
`BrokerSegmentWatcherConfig` that contains all these validations and just 
invoke `segmentWatcherConfig.validate()`` from here or should we keep them here 
itself?




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



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to