diff --git a/solr/core/src/java/org/apache/solr/cloud/ZkDistributedQueue.java b/solr/core/src/java/org/apache/solr/cloud/ZkDistributedQueue.java index fee74750cad..3a7c7502723 100644 --- a/solr/core/src/java/org/apache/solr/cloud/ZkDistributedQueue.java +++ b/solr/core/src/java/org/apache/solr/cloud/ZkDistributedQueue.java @@ -312,7 +312,7 @@ public class ZkDistributedQueue implements DistributedQueue { } // Allow this client to push up to 1% of the remaining queue capacity without rechecking. - offerPermits.set(maxQueueSize - stat.getNumChildren() / 100); + offerPermits.set(remainingCapacity / 100); } }