diff --git a/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolConductor.scala b/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolConductor.scala index 24d9666de6..fec971f3f8 100644 --- a/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolConductor.scala +++ b/akka-http-core/src/main/scala/akka/http/impl/engine/client/PoolConductor.scala @@ -140,15 +140,16 @@ private object PoolConductor { slotStates(slotIx) = slotStateAfterDisconnect(slotStates(slotIx), failed) } pull(slotIn) - val tryPull = nextSlot == -1 + val wasBlocked = nextSlot == -1 nextSlot = bestSlot() - if (tryPull) tryPullCtx() + val nowUnblocked = nextSlot != -1 + if (wasBlocked && nowUnblocked) pull(ctxIn) // get next request context } }) setHandler(out, eagerTerminateOutput) - val tryPullCtx = () ⇒ if (nextSlot != -1) pull(ctxIn) + val tryPullCtx = () ⇒ if (nextSlot != -1 && !hasBeenPulled(ctxIn)) pull(ctxIn) override def preStart(): Unit = { pull(ctxIn)