wangjialing218 opened a new pull request, #3248:
URL: https://github.com/apache/bookkeeper/pull/3248

   ### Motivation
   
   When RegionAwareEnsemblePlacementPolicy is enabled, write set of one entry 
contains bookie nodes in different region.
   When bookkeeper client read entries, the policy provide a read sequence to 
read from bookies in the same region first.  see  
   
https://github.com/apache/bookkeeper/blob/4debbbf84db09f80ffeb4154e8e6feed134be0c0/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RackawareEnsemblePlacementPolicyImpl.java#L834
   
   It depend on `myRegion` which indicate the local region of bookkeeper client 
(mostly pulsar broker).
   Local region  is not a configurable value, and it's generated by local host 
address. see 
https://github.com/apache/bookkeeper/blob/4debbbf84db09f80ffeb4154e8e6feed134be0c0/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RackawareEnsemblePlacementPolicyImpl.java#L208
   
   It's okey when there is a bookie in the same host of broker.
   But in most case, brokers were deployed in other nodes (or pod in 
kubernetes), and bookkeeper client will fail to get local region value.
   
   ### Changes
   
   Add configuration of local region for bookkeeper client.
   


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