Skip to content

Commit 8bfa6c4

Browse files
Update IndicesRequestCache.java
Signed-off-by: Kiran Prakash <[email protected]>
1 parent 9aeb82d commit 8bfa6c4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

server/src/main/java/org/opensearch/indices/IndicesRequestCache.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -515,8 +515,9 @@ private void updateStaleCountOnEntryRemoval(CleanupKey cleanupKey, RemovalNotifi
515515
return;
516516
}
517517
if (cleanupKey.entity == null) {
518-
// on shard close, the shard is still lying around so this will only happen when the shard is deleted.
519-
// we would have accounted this in staleKeysCount when the deletion of shard would have closed the associated readers
518+
// entity will only be null when the shard is closed/deleted
519+
// we would have accounted this in staleKeysCount when the closing/deletion of shard would have closed the associated
520+
// readers
520521
staleKeysCount.decrementAndGet();
521522
return;
522523
}

0 commit comments

Comments
 (0)