himanshug commented on a change in pull request #9507: optionally disable all 
of hardcoded zookeeper use
URL: https://github.com/apache/druid/pull/9507#discussion_r397320944
 
 

 ##########
 File path: 
server/src/main/java/org/apache/druid/server/coordination/BatchDataSegmentAnnouncer.java
 ##########
 @@ -99,13 +107,28 @@ public BatchDataSegmentAnnouncer(
       return rv;
     };
 
-    if (this.config.isSkipSegmentAnnouncementOnZk()) {
+    isSkipSegmentAnnouncementOnZk = !zkEnablementConfig.isEnabled() || 
config.isSkipSegmentAnnouncementOnZk();
 
 Review comment:
   this is also calling methods in
   `private final ChangeRequestHistory<DataSegmentChangeRequest> changes = new 
ChangeRequestHistory<>();`
   
   which is used by the http endpoint for segment sync.
   
   However, yeah it takes more work to announce stuff in zk so  it looks like 
that this class is primarily doing that whereas it is actually supporting both.
   If/When we are able to delete zk based segment management this class would 
shrink significantly.
   Also, unrelated, it could possibly be refactored to separate two things it 
is doing so that things are more clear. 
   However, you know my preference, just delete  zk stuff :)

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

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

Reply via email to