wangjialing218 commented on code in PR #3248:
URL: https://github.com/apache/bookkeeper/pull/3248#discussion_r929459114
##########
bookkeeper-server/src/test/java/org/apache/bookkeeper/client/TestRegionAwareEnsemblePlacementPolicy.java:
##########
@@ -1208,16 +1208,31 @@ private void
prepareNetworkTopologyForReorderTests(String myRegion) throws Excep
@Test
public void testBasicReorderReadSequenceWithLocalRegion() throws Exception
{
+ prepareNetworkTopologyForReorderTests("region2");
basicReorderReadSequenceWithLocalRegionTest("region2", false);
}
@Test
public void testBasicReorderReadLACSequenceWithLocalRegion() throws
Exception {
+ prepareNetworkTopologyForReorderTests("region2");
Review Comment:
> For your motivation, If we read all the entries from the configured
region, it may cause hot bookie, and increase the quarantine rate of the hot
bookie.
As current policy, read sequence is as follows
https://github.com/apache/bookkeeper/blob/4debbbf84db09f80ffeb4154e8e6feed134be0c0/bookkeeper-server/src/main/java/org/apache/bookkeeper/client/RackawareEnsemblePlacementPolicyImpl.java#L810
This motivation just add a configured to set the local region for client,
bookies in the configured local region will be orderd as `1. available (local)
bookies`, when these bookies become unavailable or slow, they will be orderd as
`3. R* remaining (local) bookies` or `6. slow bookies`.
> We should both test read and write.
This motivation just add a configured related to the read order of bookies
in a writeSet. IMO we do not need test write.
--
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]