updating wereChildShardsPresent hint in all cases
This commit is contained in:
parent
4d65f56038
commit
374e47b208
1 changed files with 4 additions and 1 deletions
|
|
@ -173,9 +173,10 @@ public class LeaseCleanupManager {
|
||||||
try {
|
try {
|
||||||
childShardKeys = getChildShardsFromService(shardInfo, streamIdentifier);
|
childShardKeys = getChildShardsFromService(shardInfo, streamIdentifier);
|
||||||
|
|
||||||
if (childShardKeys == null) {
|
if (CollectionUtils.isNullOrEmpty(childShardKeys)) {
|
||||||
log.error("No child shards returned from service for shard {} for {}.", shardInfo.shardId(), streamIdentifier.streamName());
|
log.error("No child shards returned from service for shard {} for {}.", shardInfo.shardId(), streamIdentifier.streamName());
|
||||||
} else {
|
} else {
|
||||||
|
wereChildShardsPresent = true;
|
||||||
updateLeaseWithChildShards(leasePendingDeletion, childShardKeys);
|
updateLeaseWithChildShards(leasePendingDeletion, childShardKeys);
|
||||||
}
|
}
|
||||||
} catch (ExecutionException e) {
|
} catch (ExecutionException e) {
|
||||||
|
|
@ -183,6 +184,8 @@ public class LeaseCleanupManager {
|
||||||
} finally {
|
} finally {
|
||||||
alreadyCheckedForGarbageCollection = true;
|
alreadyCheckedForGarbageCollection = true;
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
wereChildShardsPresent = true;
|
||||||
}
|
}
|
||||||
cleanedUpCompletedLease = cleanupLeaseForCompletedShard(lease, shardInfo, childShardKeys);
|
cleanedUpCompletedLease = cleanupLeaseForCompletedShard(lease, shardInfo, childShardKeys);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue