From 522d2577780c4622887ee0ef236fa8670281e4b2 Mon Sep 17 00:00:00 2001 From: Maksim Kotlyar Date: Mon, 19 Jun 2017 11:13:47 +0300 Subject: [PATCH] [amqp] Fixes high CPU consumption when basic get is used - usleep 100ms was added --- pkg/amqp-ext/AmqpConsumer.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pkg/amqp-ext/AmqpConsumer.php b/pkg/amqp-ext/AmqpConsumer.php index 5059b983b..c3007c2ac 100644 --- a/pkg/amqp-ext/AmqpConsumer.php +++ b/pkg/amqp-ext/AmqpConsumer.php @@ -134,6 +134,8 @@ private function receiveBasicGet($timeout) if ($message = $this->receiveNoWait()) { return $message; } + + usleep(100000); //100ms } }