pivotal-eshu commented on code in PR #7596:
URL: https://github.com/apache/geode/pull/7596#discussion_r857829063
##########
geode-core/src/main/java/org/apache/geode/internal/cache/BucketAdvisor.java:
##########
@@ -2766,23 +2766,23 @@ public boolean isShadowBucketDestroyed(String
shadowBucketPath) {
boolean checkIfAllColocatedChildBucketsBecomePrimary() {
List<PartitionedRegion> colocatedChildPRs =
getColocateNonShadowChildRegions();
- if (colocatedChildPRs.size() > 0) {
- for (PartitionedRegion partitionedRegion : colocatedChildPRs) {
- Bucket bucket =
partitionedRegion.getRegionAdvisor().getBucket(getBucket().getId());
- if (bucket != null) {
- BucketAdvisor bucketAdvisor = bucket.getBucketAdvisor();
- if (!bucketAdvisor.checkIfAllColocatedChildBucketsBecomePrimary()) {
+ if (colocatedChildPRs.isEmpty()) {
+ return checkIfBecomesPrimary();
Review Comment:
This is intended for the leaf colocated child bucket (we need to wait for it
to become primary as well). It will fail the test case if you simply change it
to return true. (This is to ensure all child buckets to become primary)
--
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]